-
Notifications
You must be signed in to change notification settings - Fork 187
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added support for bitbucket repositories (#256)
* Added support for bitbucket repositories: * added variable BITBUCKET_REPOSITORY * added short syntax in form "bb:user/repo" * added description of that to readme.md * Added test for bitbucket short syntax * Used elseif syntax in handling of git services (github, gitlab, bitbucket). * Added HEMRND/TestingFramework example located on bitbucket.org * Reformatted CMakeLists.txt in TestingFramework example * Bumped version of TestingFramework. It supports older version of c++ standard. Co-authored-by: Paweł Gorgoń <[email protected]>
- Loading branch information
1 parent
9675d46
commit 91585e3
Showing
5 changed files
with
40 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
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,7 @@ | ||
cmake_minimum_required(VERSION 3.14 FATAL_ERROR) | ||
|
||
project(CPMTestingFrameworkExample) | ||
|
||
include(../../cmake/CPM.cmake) | ||
CPMAddPackage("bb:HEMRND/[email protected]") | ||
add_test_suites(TESTS SomeTest) |
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,19 @@ | ||
#include <HEM/TestingFramework.hpp> | ||
|
||
using namespace fakeit; | ||
|
||
class ITest { | ||
public: | ||
virtual int getInt() = 0; | ||
}; | ||
|
||
TEST_CASE("Testing Framework Test") { | ||
constexpr int someIntValue = 123456; | ||
|
||
Mock<ITest> testMock; | ||
When(Method(testMock, getInt)).Return(someIntValue); | ||
|
||
int readValue = testMock.get().getInt(); | ||
|
||
REQUIRE(readValue == someIntValue); | ||
} |
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 |
---|---|---|
|
@@ -30,6 +30,12 @@ assert_equal("GITLAB_REPOSITORY;foo/bar" "${args}") | |
cpm_parse_add_package_single_arg("gl:foo/Bar" args) | ||
assert_equal("GITLAB_REPOSITORY;foo/Bar" "${args}") | ||
|
||
cpm_parse_add_package_single_arg("bb:foo/bar" args) | ||
assert_equal("BITBUCKET_REPOSITORY;foo/bar" "${args}") | ||
|
||
cpm_parse_add_package_single_arg("bb:foo/Bar" args) | ||
assert_equal("BITBUCKET_REPOSITORY;foo/Bar" "${args}") | ||
|
||
cpm_parse_add_package_single_arg("https://github.com/cpm-cmake/[email protected]" args) | ||
assert_equal("GIT_REPOSITORY;https://github.com/cpm-cmake/CPM.cmake.git;VERSION;0.30.5" "${args}") | ||
|
||
|