Skip to content

Commit edfc844

Browse files
committed
fix: Updating MWMS tests to check for log lines
1 parent 4e1f0af commit edfc844

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

test/integration/sagemaker/test_multi_worker_mirrored.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
RESOURCE_PATH = os.path.join(os.path.dirname(__file__), "..", "..", "resources")
2222

2323

24-
def test_multi_node(sagemaker_session, instance_type, image_uri, tmpdir, framework_version):
24+
def test_multi_node(sagemaker_session, instance_type, image_uri, tmpdir, framework_version, capsys):
2525
estimator = TensorFlow(
2626
entry_point=os.path.join(RESOURCE_PATH, "multi_worker_mirrored", "train_dummy.py"),
2727
role="SageMakerRole",
@@ -36,4 +36,8 @@ def test_multi_node(sagemaker_session, instance_type, image_uri, tmpdir, framewo
3636
sagemaker_session=sagemaker_session,
3737
)
3838
estimator.fit(job_name=unique_name_from_base("test-tf-mwms"))
39-
raise NotImplementedError("Yet to add assertion")
39+
captured = capsys.readouterr()
40+
logs = captured.out + captured.err
41+
assert 'Running distributed training job with multi_worker_mirrored_strategy setup' in logs
42+
assert 'TF_CONFIG=' in logs
43+

0 commit comments

Comments
 (0)