Skip to content

Commit

Permalink
cleanup test
Browse files Browse the repository at this point in the history
  • Loading branch information
zchrissirhcz committed Nov 20, 2024
1 parent a451c00 commit 161f6dc
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions test.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,8 @@ def check_build(self, project_name, args=''):
def test_artifact_path(self):
if PLATFORM.startswith('vs'):
# Ninja Multi-Config
out = self.check_generate('artifacts_path', args='-G "Ninja Multi-Config" -DCMAKE_TOOLCHAIN_FILE="../../toolchains/Windows.MSVC.toolchain.cmake"')
print(out)
out = self.check_build('artifacts_path', '--config Release')
print(out)
self.check_generate('artifacts_path', args='-G "Ninja Multi-Config" -DCMAKE_TOOLCHAIN_FILE="../../toolchains/Windows.MSVC.toolchain.cmake"')
self.check_build('artifacts_path', '--config Release')
self.assertTrue(os.path.exists('build/artifacts_path/Release/foo_static.lib'))
self.assertTrue(os.path.exists('build/artifacts_path/Release/foo_shared.dll'))
self.assertTrue(os.path.exists('build/artifacts_path/Release/hello.exe'))
Expand All @@ -65,10 +63,8 @@ def test_artifact_path(self):
shutil.rmtree('build/artifacts_path')

# Ninja
out = self.check_generate('artifacts_path', args='-G Ninja -DCMAKE_TOOLCHAIN_FILE="../../toolchains/Windows.MSVC.toolchain.cmake"')
print(out)
out = self.check_build('artifacts_path', '--config Release')
print(out)
self.check_generate('artifacts_path', args='-G Ninja -DCMAKE_TOOLCHAIN_FILE="../../toolchains/Windows.MSVC.toolchain.cmake"')
self.check_build('artifacts_path', '--config Release')
self.assertTrue(os.path.exists('build/artifacts_path/foo_static.lib'))
self.assertTrue(os.path.exists('build/artifacts_path/foo_shared.dll'))
self.assertTrue(os.path.exists('build/artifacts_path/hello.exe'))
Expand Down

0 comments on commit 161f6dc

Please sign in to comment.