diff options
author | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2023-02-13 15:31:01 +0100 |
---|---|---|
committer | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2023-03-03 16:21:14 +0100 |
commit | 91f33def73223721ad91f99040158f3ff54dffab (patch) | |
tree | 1781e6e22ff169fafc81697d6502bc9dc9f396cb /test | |
parent | cab6734ee8d6ffc5a001144aead0ce6c79c90048 (diff) | |
download | justbuild-91f33def73223721ad91f99040158f3ff54dffab.tar.gz |
GitRepoRemote: Correctly honor SSL certification settings in fetch and commit update
Uses the SSL certification utility method to correctly set the
certification check options for the remote URL libgit2 calls.
Due to the fact that remote operations are done via a temporary
repository to allow concurrent work, the correct repository
configuration needs to be interrogated. Thankfully, libgit2
provides a thread safe config snapshot object to be used in
such scenarios.
Also updates the existing GitRepoRemote tests accordingly.
Diffstat (limited to 'test')
-rw-r--r-- | test/other_tools/git_operations/git_repo_remote.test.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/other_tools/git_operations/git_repo_remote.test.cpp b/test/other_tools/git_operations/git_repo_remote.test.cpp index 89f67d41..4b7a2a77 100644 --- a/test/other_tools/git_operations/git_repo_remote.test.cpp +++ b/test/other_tools/git_operations/git_repo_remote.test.cpp @@ -185,7 +185,7 @@ TEST_CASE("Single-threaded real repository remote operations", // remote ls auto remote_commit = repo_remote_ls_bare->GetCommitFromRemote( - *repo_path, "master", logger); + nullptr, *repo_path, "master", logger); REQUIRE(remote_commit); CHECK(*remote_commit == kRootCommit); } @@ -198,7 +198,7 @@ TEST_CASE("Single-threaded real repository remote operations", // fetch CHECK(repo_fetch_all_bare->FetchFromRemote( - *repo_path, std::nullopt, logger)); + nullptr, *repo_path, std::nullopt, logger)); } SECTION("Fetch branch from remote") { @@ -211,7 +211,7 @@ TEST_CASE("Single-threaded real repository remote operations", // fetch CHECK(repo_fetch_branch_bare->FetchFromRemote( - *repo_path, "master", logger)); + nullptr, *repo_path, "master", logger)); } } |