Skip to content

Commit 9a61f71

Browse files
authored
Fixed Multiple Args Testing Issue
Differential Revision: D55525717 Pull Request resolved: #868
1 parent e4d7a90 commit 9a61f71

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

torchx/cli/test/cmd_run_test.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def test_run_with_multiple_schedule_args(self) -> None:
6161

6262
args = [
6363
"--scheduler",
64-
"local_conda",
64+
"local_cwd",
6565
"--scheduler",
6666
"local_cwd",
6767
]

torchx/cli/test/main_test.py

+4
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
from pathlib import Path
1414
from unittest.mock import MagicMock, patch
1515

16+
from torchx.cli.argparse_util import ArgOnceAction, torchxconfig
17+
1618
from torchx.cli.cmd_base import SubCommand
1719
from torchx.cli.main import get_sub_cmds, main
1820

@@ -37,6 +39,8 @@ def setUp(self) -> None:
3739

3840
def tearDown(self) -> None:
3941
os.chdir(self.old_cwd)
42+
ArgOnceAction.called_args = set()
43+
torchxconfig.called_args = set()
4044

4145
def test_run_abs_config_path(self) -> None:
4246
main(

0 commit comments

Comments
 (0)