Skip to content

Commit 3a2fec7

Browse files
committed
Split parse_gpu_targets test cases
(cherry picked from commit 5024cf8)
1 parent d0f4d31 commit 3a2fec7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

build/rocm/test_ci_build.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,13 @@ def load_ci_build():
3333

3434

3535
class CIBuildTestCase(unittest.TestCase):
36-
def test_parse_gpu_targets(self):
36+
def test_parse_gpu_targets_spaces(self):
3737
targets = ["gfx908", "gfx940", "gfx1201"]
38-
3938
r = ci_build.parse_gpu_targets(" ".join(targets))
4039
self.assertEqual(r, targets)
4140

41+
def test_parse_gpu_targets_commas(self):
42+
targets = ["gfx908", "gfx940", "gfx1201"]
4243
r = ci_build.parse_gpu_targets(",".join(targets))
4344
self.assertEqual(r, targets)
4445

@@ -47,6 +48,7 @@ def test_parse_gpu_targets_empty_string(self):
4748
r = ci_build.parse_gpu_targets("")
4849
self.assertEqual(r, expected)
4950

51+
def test_parse_gpu_targets_whitespace_only(self):
5052
self.assertRaises(ValueError, ci_build.parse_gpu_targets, " ")
5153

5254
def test_parse_gpu_targets_invalid_arch(self):

0 commit comments

Comments
 (0)