Skip to content

Commit 2386420

Browse files
committed
fix lint issues
1 parent 285b5a8 commit 2386420

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

test/xpu/xpu_test_utils.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1092,16 +1092,15 @@ def copy_tests(
10921092

10931093
def launch_test(test_case, skip_list=None, exe_list=None):
10941094
os.environ["PYTORCH_TEST_WITH_SLOW"] = "1"
1095-
module_name = test_case.replace('.py', '').replace('/', '.').replace('\\', '.')
1095+
module_name = test_case.replace(".py", "").replace("/", ".").replace("\\", ".")
10961096
if skip_list is not None:
10971097
skip_options = ' -k "not ' + skip_list[0]
10981098
for skip_case in skip_list[1:]:
10991099
skip_option = " and not " + skip_case
11001100
skip_options += skip_option
11011101
skip_options += '"'
11021102
test_command = (
1103-
f"pytest --junit-xml=./op_ut_with_skip.{module_name}.xml"
1104-
+ test_case
1103+
f"pytest --junit-xml=./op_ut_with_skip.{module_name}.xml" + test_case
11051104
)
11061105
test_command += skip_options
11071106
elif exe_list is not None:
@@ -1111,13 +1110,11 @@ def launch_test(test_case, skip_list=None, exe_list=None):
11111110
exe_options += exe_option
11121111
exe_options += '"'
11131112
test_command = (
1114-
f"pytest --junit-xml=./op_ut_with_exe.{module_name}.xml"
1115-
+ test_case
1113+
f"pytest --junit-xml=./op_ut_with_exe.{module_name}.xml" + test_case
11161114
)
11171115
test_command += exe_options
11181116
else:
11191117
test_command = (
1120-
f"pytest --junit-xml=./op_ut_with_all.{module_name}.xml"
1121-
+ test_case
1118+
f"pytest --junit-xml=./op_ut_with_all.{module_name}.xml" + test_case
11221119
)
11231120
return os.system(test_command)

0 commit comments

Comments
 (0)