Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update conan new modern templates (#9516)
* update conan new modern templates * use CMake.install() * fix broken test
- Loading branch information
1 parent
aae78ea
commit 313552e
Showing
10 changed files
with
223 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 19 additions & 4 deletions
23
conans/test/functional/toolchains/cmake/test_v2_cmake_template.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,31 @@ | ||
from conans.test.utils.tools import TestClient | ||
|
||
|
||
def test_v2_cmake_template(): | ||
def test_cmake_lib_template(): | ||
client = TestClient(path_with_spaces=False) | ||
client.run("new hello/0.1 --template=v2_cmake") | ||
client.run("new hello/0.1 --template=cmake_lib") | ||
# Local flow works | ||
client.run("install . -if=install") | ||
client.run("build . -if=install") | ||
|
||
# Create works | ||
client.run("create .") | ||
assert "Hello World Release!" in client.out | ||
assert "hello/0.1: Hello World Release!" in client.out | ||
|
||
client.run("create . -s build_type=Debug") | ||
assert "Hello World Debug!" in client.out | ||
assert "hello/0.1: Hello World Debug!" in client.out | ||
|
||
|
||
def test_cmake_exe_template(): | ||
client = TestClient(path_with_spaces=False) | ||
client.run("new greet/0.1 --template=cmake_exe") | ||
# Local flow works | ||
client.run("install . -if=install") | ||
client.run("build . -if=install") | ||
|
||
# Create works | ||
client.run("create .") | ||
assert "greet/0.1: Hello World Release!" in client.out | ||
|
||
client.run("create . -s build_type=Debug") | ||
assert "greet/0.1: Hello World Debug!" in client.out |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.