!48438 change to check log

Merge pull request !48438 from baihuawei/pynative_ascend_mpi_8p_resnet50
This commit is contained in:
i-robot 2023-02-10 03:19:07 +00:00 committed by Gitee
commit 31f7ccacd4
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 3 additions and 1 deletions

View File

@ -25,5 +25,7 @@ def test_pynative_resnet50_ascend_8p_mpi():
Description: test PyNative ResNet50 8p with mpirun
Expectation: success, return_code==0
"""
return_code = os.system("mpirun -n 8 pytest -s test_pynative_resnet50_ascend.py::test_pynative_resnet50_with_mpi")
os.system("mpirun -n 8 pytest -s test_pynative_resnet50_ascend.py::test_pynative_resnet50_with_mpi"
" >stdout.log 2>&1")
return_code = os.system(r"grep '1 passed' stdout.log")
assert return_code == 0