From d72543780dbd5bb773358c4d6e2050e9cf03f8dd Mon Sep 17 00:00:00 2001 From: Vipul Cariappa Date: Sat, 28 Sep 2024 04:55:41 +0000 Subject: [PATCH] [test] Update tags tests fixed by compiler-research/CppInterOp#329 & compiler-research/CPyCppyy#61 --- test/test_datatypes.py | 2 -- test/test_doc_features.py | 2 -- test/test_fragile.py | 1 - test/test_lowlevel.py | 1 - test/test_stltypes.py | 5 ++--- test/test_templates.py | 4 +--- 6 files changed, 3 insertions(+), 12 deletions(-) diff --git a/test/test_datatypes.py b/test/test_datatypes.py index aae32b04..84e052c0 100644 --- a/test/test_datatypes.py +++ b/test/test_datatypes.py @@ -661,7 +661,6 @@ def test09_global_ptr(self): assert gbl.g_pod.m_int == 43 assert gbl.g_pod.m_double == 2.14 - @mark.xfail def test10_enum(self): """Test access to enums""" @@ -781,7 +780,6 @@ class Test { assert type(sc.vraioufaux.faux) == bool # no bool as base class assert isinstance(sc.vraioufaux.faux, bool) - @mark.xfail def test12_enum_scopes(self): """Enum accessibility and scopes""" diff --git a/test/test_doc_features.py b/test/test_doc_features.py index 72627da5..0b2fbd66 100644 --- a/test/test_doc_features.py +++ b/test/test_doc_features.py @@ -200,7 +200,6 @@ def test_casting(self): e = bind_object(addressof(d), Abstract) assert type(e) == cppyy.gbl.Abstract - @mark.xfail(condition=IS_CLANG_REPL, reason="Fails with ClangRepl") def test_classes_and_structs(self): import cppyy from cppyy.gbl import Concrete, Namespace @@ -939,7 +938,6 @@ def test06_c_char_p(self): val = createit(ptr) assert destroyit(ptr) == val - @mark.xfail def test07_array_of_arrays(self): """Example of array of array usage""" diff --git a/test/test_fragile.py b/test/test_fragile.py index 55f9d3ad..83bff671 100644 --- a/test/test_fragile.py +++ b/test/test_fragile.py @@ -284,7 +284,6 @@ def test11_dir(self): assert 'operator<' not in dirS - @mark.xfail(condition=IS_CLANG_REPL, reason="Fails with ClangRepl") def test12_imports(self): """Test ability to import from namespace (or fail with ImportError)""" diff --git a/test/test_lowlevel.py b/test/test_lowlevel.py index 1c273857..e89cef5b 100644 --- a/test/test_lowlevel.py +++ b/test/test_lowlevel.py @@ -32,7 +32,6 @@ def test01_llv_type(self): assert cppyy.types.LowLevelView - @mark.xfail def test02_builtin_cpp_casts(self): """C++ casting of builtin types""" diff --git a/test/test_stltypes.py b/test/test_stltypes.py index 53751564..a5a561b1 100644 --- a/test/test_stltypes.py +++ b/test/test_stltypes.py @@ -1909,7 +1909,6 @@ def setup_class(cls): import cppyy cls.stltypes = cppyy.load_reflection_info(cls.test_dct) - @mark.xfail(condition=IS_CLANG_REPL, reason="Fails with ClangRepl") def test01_basics(self): """Test behavior of std::exception derived classes""" @@ -1950,7 +1949,7 @@ def test01_basics(self): assert YourError.__cpp_name__ == 'ErrorNamespace::YourError' assert YourError.__module__ == 'cppyy.gbl.ErrorNamespace' - @mark.xfail(condition = IS_MAC or (IS_LINUX and IS_CLANG_REPL), reason="Fails on OS X") + @mark.xfail(condition=IS_MAC, reason="Fails on OS X") def test02_raising(self): """Raise a C++ std::exception derived class as a Python excption""" @@ -1987,7 +1986,7 @@ def raiseit(cls): except cppyy.gbl.YourError as e: assert e.what() == 'Oops' - @mark.xfail(condition=(IS_CLANG_REPL) or ((IS_MAC_ARM or IS_MAC_X86) and (not IS_CLANG_REPL)), reason="Fails with ClangRepl and OS X Cling") + @mark.xfail(condition=(IS_MAC_ARM or IS_MAC_X86) and (not IS_CLANG_REPL), reason="Fails with OS X Cling") def test03_memory(self): """Memory handling of C++ c// helper for exception base class testing""" diff --git a/test/test_templates.py b/test/test_templates.py index 527e8a01..56225b80 100644 --- a/test/test_templates.py +++ b/test/test_templates.py @@ -146,7 +146,7 @@ def test04_variadic_function(self): assert cppyy.gbl.test04_variadic_func['int', 'double', 'void*']() == 3 - @mark.xfail + @mark.xfail(condition=not IS_CLANG_REPL, reason="Fails with Cling") def test05_variadic_overload(self): """Call an overloaded variadic function""" @@ -342,7 +342,6 @@ def test13_using_templated_method(self): assert type(d.get3()) == int assert d.get3() == 5 - @mark.xfail(condition=IS_CLANG_REPL, reason="Fails on Clang-REPL") def test14_templated_return_type(self): """Use of a templated return type""" @@ -565,7 +564,6 @@ def test21_type_deduction_with_conversion(self): assert l2v.test3[int]([d1]) == 1 assert l2v.test3[int]([d1, d1]) == 2 - @mark.xfail(condition=IS_CLANG_REPL, reason="Fails on Clang-REPL") def test22_type_deduction_of_proper_integer_size(self): """Template type from integer arg should be big enough"""