| 1 |
|
| 2 |
|
| 3 |
from conans import ConanFile, CMake |
| 4 |
import os |
| 5 |
|
| 6 |
|
| 7 |
class TestPackageConan(ConanFile): |
| 8 |
settings = "os", "compiler", "build_type", "arch" |
| 9 |
generators = "cmake_find_package_multi", "cmake" |
| 10 |
|
| 11 |
def build(self): |
| 12 |
cmake = CMake(self) |
| 13 |
cmake.configure() |
| 14 |
cmake.build() |
| 15 |
|
| 16 |
def test(self): |
| 17 |
assert os.path.isfile(os.path.join( |
| 18 |
self.deps_cpp_info["catch2"].rootpath, "licenses", "LICENSE.txt")) |
| 19 |
bin_path = os.path.join("bin", "test_package") |
| 20 |
self.run("%s -s" % bin_path, run_environment=True) |