diff --git a/tests/test_va_list_tag_removal.py b/tests/test_va_list_tag_removal.py index 25a001d4..2a675665 100644 --- a/tests/test_va_list_tag_removal.py +++ b/tests/test_va_list_tag_removal.py @@ -24,7 +24,7 @@ __code = os.linesep.join(['struct a{};']) known_typedefs = ["__int128_t", "__uint128_t", "__builtin_va_list"] known_typedefs_llvm39 = known_typedefs + ["__builtin_ms_va_list"] -known_classes = ["a", "__va_list_tag"] +known_classes = ["a"] known_classes_llvm39 = known_classes + ["__NSConstantString_tag"] @@ -48,9 +48,6 @@ def test_keep_va_list_tag(): variables = [ i for i in decls if isinstance(i, declarations.variable_t)] - tag = "__va_list_tag" - - assert tag in [class_.name for class_ in classes] assert "a" in [class_.name for class_ in classes] if len(classes) == 2: for c in known_classes: @@ -60,7 +57,6 @@ def test_keep_va_list_tag(): # This is for llvm 3.9 assert c in [cl.name for cl in classes] - assert len(typedefs) == 4 or len(typedefs) == 5 if len(typedefs) == 5: # This is for llvm 3.9. The class __va_list_tag struct is still # there but the typedef is gone @@ -72,8 +68,6 @@ def test_keep_va_list_tag(): for t in known_typedefs: assert t in [ty.name for ty in typedefs] - assert tag in [var.decl_string.split("::")[1] for var in variables] - # 4 variables in __va_list_tag, and 4 more in __NSConstantString_tag # for llvm 3.9 assert len(variables) == 4 or len(variables) == 8 @@ -106,7 +100,6 @@ def test_remove_va_list_tag(): assert len(classes) == 1 assert tag not in [ty.name for ty in typedefs] - assert len(typedefs) == 3 or len(typedefs) == 4 if len(typedefs) == 4: # This is for llvm 3.9 for t in known_typedefs_llvm39: