Skip to content

Commit

Permalink
add unit test for static backend option
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelClifford committed Aug 21, 2023
1 parent 502300b commit 3d32e73
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions torchx/components/test/dist_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ def test_ddp_debug(self) -> None:
for k, v in _TORCH_DEBUG_FLAGS.items():
self.assertEqual(env[k], v)

def test_ddp_rdzv_backend_static(self) -> None:
app = ddp(script="foo.py", rdzv_backend="static")
cmd = app.roles[0].args[1]
self.assertTrue("--rdzv_backend static" in cmd)
self.assertTrue("--node_rank" in cmd)



class SpmdTest(ComponentTestCase):
def test_validate_spmd(self) -> None:
Expand Down

0 comments on commit 3d32e73

Please sign in to comment.