From 62d8c18b6b259b359605e8041d6a0af842b0a23f Mon Sep 17 00:00:00 2001 From: Mehrdad Hessar Date: Wed, 11 May 2022 01:50:40 -0700 Subject: [PATCH] [USMP] Fix assert condition for TVMBackendAllocWorkspace (#11270) * Fix test condition * fix --- tests/python/relay/aot/test_crt_aot_usmp.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/python/relay/aot/test_crt_aot_usmp.py b/tests/python/relay/aot/test_crt_aot_usmp.py index 86e0d18021fd..ab7fb4167cac 100644 --- a/tests/python/relay/aot/test_crt_aot_usmp.py +++ b/tests/python/relay/aot/test_crt_aot_usmp.py @@ -54,9 +54,9 @@ def check_for_no_tvm_backendallocworkspace_calls(mod: tvm.runtime.module): dso_mod.type_key == "c" ), 'Current CRT AoT codegen flow should only produce type "c" runtime modules' source = dso_mod.get_source() - source.count( - "TVMBackendAllocWorkspace" - ) == 0, "This is failing because USMP was unable to plan for every tir.allocate node" + assert ( + source.count("TVMBackendAllocWorkspace") == 0 + ), "This is failing because USMP was unable to plan for every tir.allocate node" @pytest.mark.parametrize(