diff options
author | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2024-08-19 16:01:16 +0200 |
---|---|---|
committer | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2024-08-26 12:12:00 +0200 |
commit | c889b852a652115f4a6936a96ebdee9410571997 (patch) | |
tree | e553f21acab38fc4466adda19a378952df6a7eb6 /test | |
parent | a312e71b59340f7b6d8dc5aac9202137ae81d02b (diff) | |
download | justbuild-c889b852a652115f4a6936a96ebdee9410571997.tar.gz |
GitOps: Pass source directory to GitInitialCommit operation
While there, ensure optional Git operation parameters are checked
before use for the operations that require them.
Diffstat (limited to 'test')
-rw-r--r-- | test/other_tools/git_operations/critical_git_ops.test.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/other_tools/git_operations/critical_git_ops.test.cpp b/test/other_tools/git_operations/critical_git_ops.test.cpp index ac1f371c..c1494bcf 100644 --- a/test/other_tools/git_operations/critical_git_ops.test.cpp +++ b/test/other_tools/git_operations/critical_git_ops.test.cpp @@ -173,7 +173,8 @@ TEST_CASE("Critical git operations", "[critical_git_op_map]") { { path_init_commit, // target_path "", // git_hash - "Init commit" // message + "Init commit", // message + path_init_commit // source_path }, .op_type = GitOpType::INITIAL_COMMIT}, GitOpKey{.params = @@ -181,6 +182,7 @@ TEST_CASE("Critical git operations", "[critical_git_op_map]") { path_init_bare, // target_path "", // git_hash std::nullopt, // message + std::nullopt, // source_path true // init_bare }, .op_type = GitOpType::ENSURE_INIT}, @@ -189,6 +191,7 @@ TEST_CASE("Critical git operations", "[critical_git_op_map]") { path_init_non_bare, // target_path "", // git_hash std::nullopt, // message + std::nullopt, // source_path false // init_bare }, .op_type = GitOpType::ENSURE_INIT}, |