def pytest_configure(config):
# when marking argon_disabled for a whole test, but flex_disabled only on one
# parametrized version of that test, the argon marking disappeared
config.flex_and_argon_disabled = pytest.mark.xfail(config.getvalue("transformer") == "flexgpu" or
config.getvalue("transformer") == "argon",
reason="Not supported by argon or flex backend",
strict=True)
config.argon_disabled = pytest.mark.xfail(config.getvalue("transformer") == "argon",
reason="Not supported by argon backend",
strict=True)
config.flex_disabled = pytest.mark.xfail(config.getvalue("transformer") == "flexgpu",
reason="Failing test for Flex",
strict=True)
config.hetr_and_cpu_enabled_only = pytest.mark.xfail(config.getvalue("transformer") != "hetr" and
config.getvalue("transformer") != "cpu",
reason="Only Hetr/CPU and CPU transformers supported",
strict=True)
config.flex_skip = pytest.mark.skipif(config.getvalue("transformer") == "flexgpu",
reason="Randomly failing test for Flex")
config.argon_skip = pytest.mark.skipif(config.getvalue("transformer") == "argon")
config.flex_skip_now = pytest.skip if config.getvalue("transformer") == "flexgpu" \
else pass_method
config.argon_skip_now = pytest.skip if config.getvalue("transformer") == "argon" \
else pass_method
评论列表
文章目录