Skip to content

Commit f93eab8

Browse files
test: display the cpu template name
The skip message attempted to interpolate a variable, but was missing the 'f' prefix, so the variable wasn't substituted. Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
1 parent 94660fe commit f93eab8

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tests/integration_tests/functional/test_cpu_features_x86_64.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -541,7 +541,7 @@ def test_cpu_cpuid_snapshot(microvm_factory, guest_kernel, rootfs, cpu_template_
541541
"""
542542
cpu_template_name = get_cpu_template_name(cpu_template_any)
543543
if cpu_template_name not in MSR_SUPPORTED_TEMPLATES:
544-
pytest.skip("This test does not support {cpu_template_name} template.")
544+
pytest.skip(f"This test does not support {cpu_template_name} template.")
545545

546546
shared_names = SNAPSHOT_RESTORE_SHARED_NAMES
547547

@@ -611,7 +611,7 @@ def test_cpu_cpuid_restore(microvm_factory, guest_kernel, cpu_template_any):
611611
"""
612612
cpu_template_name = get_cpu_template_name(cpu_template_any)
613613
if cpu_template_name not in MSR_SUPPORTED_TEMPLATES:
614-
pytest.skip("This test does not support {cpu_template_name} template.")
614+
pytest.skip(f"This test does not support {cpu_template_name} template.")
615615

616616
shared_names = SNAPSHOT_RESTORE_SHARED_NAMES
617617
snapshot_artifacts_dir = (
@@ -646,8 +646,8 @@ def test_cpu_template(uvm_plain_any, cpu_template_any, microvm_factory):
646646
supported CPU templates.
647647
"""
648648
cpu_template_name = get_cpu_template_name(cpu_template_any)
649-
if cpu_template_name not in ["T2", "T2S", "SPR_TO_T2_5.10", "SPR_TO_T2_6.1" "C3"]:
650-
pytest.skip("This test does not support {cpu_template_name} template.")
649+
if cpu_template_name not in ["T2", "T2S", "SPR_TO_T2_5.10", "SPR_TO_T2_6.1", "C3"]:
650+
pytest.skip(f"This test does not support {cpu_template_name} template.")
651651

652652
test_microvm = uvm_plain_any
653653
test_microvm.spawn()

0 commit comments

Comments
 (0)