Skip to content

Commit

Permalink
add mark to qbs tests
Browse files Browse the repository at this point in the history
  • Loading branch information
czoido committed Nov 4, 2024
1 parent 0fb08e5 commit 5b90dfb
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/integration/toolchains/qbs/test_qbsdeps.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
from conans.util.files import load


@pytest.mark.tool("qbs")
def test_empty_package():
# Checks default values generated by conan for cpp_info
client = TestClient()
Expand Down Expand Up @@ -40,6 +41,7 @@ def test_empty_package():
assert module_content.get('options') == {}


@pytest.mark.tool("qbs")
def test_empty_dirs():
# Checks that we can override default values with empty directories
conanfile = textwrap.dedent('''
Expand Down Expand Up @@ -84,6 +86,7 @@ def package_info(self):
assert module_content.get('options') == {}


@pytest.mark.tool("qbs")
def test_pkg_config_name():
# Checks we can override module name using the "pkg_config_name" property
conanfile = textwrap.dedent('''
Expand All @@ -104,6 +107,7 @@ def package_info(self):
assert os.path.exists(module_path)


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('host_os, arch, build_type', [
('Linux', 'x86_64', 'Debug'),
('Linux', 'x86_64', 'Release'),
Expand Down Expand Up @@ -140,6 +144,7 @@ class Recipe(ConanFile):
assert module_content['settings'].get('build_type') == build_type


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('shared', ['False', 'True'])
def test_options(shared):
conanfile = textwrap.dedent('''
Expand All @@ -165,6 +170,7 @@ class Recipe(ConanFile):
assert module_content['options'].get('shared') == shared


@pytest.mark.tool("qbs")
def test_components():
"""
Checks a package with multiple components.
Expand Down Expand Up @@ -217,6 +223,7 @@ def package_info(self):
]


@pytest.mark.tool("qbs")
def test_cpp_info_requires():
"""
Testing a complex structure like:
Expand Down Expand Up @@ -365,6 +372,7 @@ def package_info(self):


# see https://github.com/conan-io/conan/issues/10341
@pytest.mark.tool("qbs")
def test_components_conflict():
""" If component has the same name as the root package, skip root package
"""
Expand Down
7 changes: 7 additions & 0 deletions test/integration/toolchains/qbs/test_qbsprofile.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def exe_suffix():
}


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('compiler, version, system', [
('gcc', '13', 'Linux'),
('clang', '15', 'Linux'),
Expand Down Expand Up @@ -63,6 +64,7 @@ class Recipe(ConanFile):
assert f'cpp.cxxCompilerName:{cxx}' in settings_content


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('compiler, version, system, cc, cxx', [
('gcc', '13', 'Linux', 'gcc', 'g++'),
('clang', '15', 'Linux', 'clang', 'clang++'),
Expand Down Expand Up @@ -102,6 +104,7 @@ class Recipe(ConanFile):
assert f'cpp.cxxCompilerName:{cxx}' in settings_content


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('compiler, version, system, cc, cxx', [
('gcc', '13', 'Linux', 'gcc', 'g++'),
('clang', '15', 'Linux', 'clang', 'clang++'),
Expand Down Expand Up @@ -142,6 +145,7 @@ class Recipe(ConanFile):
assert f'cpp.cxxCompilerName:{cxx}' in settings_content


@pytest.mark.tool("qbs")
@pytest.mark.parametrize('system, compiler, version, build_type, arch, cppstd', [
('Linux', 'gcc', '13', 'Release', 'x86_64', '17'),
('Linux', 'gcc', '13', 'Debug', 'x86_64', '14'),
Expand Down Expand Up @@ -191,6 +195,7 @@ class Recipe(ConanFile):
# TODO: cpp.runtimeLibrary (MSVC only)


@pytest.mark.tool("qbs")
def test_options_from_conf():
client = TestClient()

Expand Down Expand Up @@ -233,6 +238,7 @@ class Recipe(ConanFile):
assert "cpp.driverLinkerFlags:['-s']" in settings_content


@pytest.mark.tool("qbs")
def test_options_extra():
client = TestClient()

Expand Down Expand Up @@ -282,6 +288,7 @@ def generate(self):
assert "cpp.driverLinkerFlags:['-s']" in settings_content


@pytest.mark.tool("qbs")
def test_sysroot():
client = TestClient()

Expand Down

0 comments on commit 5b90dfb

Please sign in to comment.