Skip to content

Commit e6866a9

Browse files
committed
Use lower case test name in test_spec.json
The `mbedgt` command allows users to run a single test suite using the `-n` option. But it has a limitation that the test name in `test_spec.json` must be in lower case, otherwise the user-specified case cannot be found. The test name passed by the user via `-n` can be in upper case - mbedgt converts that to lower case.
1 parent 9d9d70e commit e6866a9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

test_psa_target.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ def _build_regression_test(args, test_spec):
289289

290290
# update the test_spec
291291
test_group = _get_test_group(args)
292-
test_spec["builds"][test_group]["tests"][suite] = _get_test_spec(
292+
test_spec["builds"][test_group]["tests"][suite.lower()] = _get_test_spec(
293293
args, suite, binary_name
294294
)
295295

@@ -326,9 +326,9 @@ def _build_compliance_test(args, test_spec):
326326
# The PSA tests currently provide no option to skip known failures.
327327
# Users can still run the Crypto suite manually without automation.
328328
if suite != "CRYPTO":
329-
test_spec["builds"][test_group]["tests"][suite] = _get_test_spec(
330-
args, suite, binary_name
331-
)
329+
test_spec["builds"][test_group]["tests"][
330+
suite.lower()
331+
] = _get_test_spec(args, suite, binary_name)
332332

333333

334334
def _get_parser():

0 commit comments

Comments
 (0)