-
Notifications
You must be signed in to change notification settings - Fork 175
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix download_command by declaring it a multi-value option (#473)
- Loading branch information
1 parent
52ee7c9
commit 16c6a3b
Showing
2 changed files
with
27 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
require_relative './lib' | ||
|
||
# Tests using a multi-argumenet download command to fetch a dependency | ||
|
||
class DownloadCommand < IntegrationTest | ||
|
||
def test_fetch_dependency_using_download_command | ||
prj = make_project from_template: 'using-adder' | ||
|
||
prj.create_lists_from_default_template package: <<~PACK | ||
set(DOWNLOAD_DIR ${CMAKE_BINARY_DIR}/_deps/testpack-adder-src) | ||
CPMAddPackage( | ||
NAME testpack-adder | ||
SOURCE_DIR ${DOWNLOAD_DIR} | ||
DOWNLOAD_COMMAND git clone --depth 1 --branch v1.0.0 https://github.com/cpm-cmake/testpack-adder.git ${DOWNLOAD_DIR} | ||
OPTIONS "ADDER_BUILD_TESTS OFF" | ||
) | ||
PACK | ||
|
||
# configure with unpopulated cache | ||
assert_success prj.configure | ||
assert_success prj.build | ||
end | ||
|
||
end |