Ejemplo n.º 1
0
import pytest
import platform
import textwrap
import unittest

from parameterized import parameterized
import pytest

from conans.test.assets.sources import gen_function_cpp, gen_function_h
from conans.test.functional.toolchains.meson._base import get_meson_version
from conans.test.utils.tools import TestClient


@pytest.mark.toolchain
@pytest.mark.tool_meson
@pytest.mark.skipif(get_meson_version() < "0.56.0",
                    reason="requires meson >= 0.56.0")
class AndroidToolchainMesonTestCase(unittest.TestCase):

    _conanfile_py = textwrap.dedent("""
    from conans import ConanFile, tools
    from conan.tools.meson import Meson, MesonToolchain


    class App(ConanFile):
        settings = "os", "arch", "compiler", "build_type"
        options = {"shared": [True, False], "fPIC": [True, False]}
        default_options = {"shared": False, "fPIC": True}

        def config_options(self):
            if self.settings.os == "Windows":
Ejemplo n.º 2
0
import pytest
import platform
import textwrap
import unittest

from parameterized import parameterized
import pytest

from conans.test.assets.sources import gen_function_cpp, gen_function_h
from conans.test.functional.toolchains.meson._base import get_meson_version
from conans.test.utils.tools import TestClient


@pytest.mark.toolchain
@pytest.mark.tool_meson
@pytest.mark.skipif(get_meson_version() < "0.56.0", reason="requires meson >= 0.56.0")
class AndroidToolchainMesonTestCase(unittest.TestCase):

    _conanfile_py = textwrap.dedent("""
    from conans import ConanFile, tools
    from conan.tools.meson import Meson, MesonToolchain


    class App(ConanFile):
        settings = "os", "arch", "compiler", "build_type"
        options = {"shared": [True, False], "fPIC": [True, False]}
        default_options = {"shared": False, "fPIC": True}

        def config_options(self):
            if self.settings.os == "Windows":
                del self.options.fPIC