summaryrefslogtreecommitdiff
path: root/tests/online/fetch.c
diff options
context:
space:
mode:
authorCarlos Martín Nieto <cmn@dwim.me>2014-06-06 15:01:45 +0200
committerCarlos Martín Nieto <cmn@dwim.me>2014-09-30 15:42:32 +0200
commit3f8942052306a9d62521bdb6e6d5e7636bc5526e (patch)
tree739988344f450431fec435e2dfde626c75493ec2 /tests/online/fetch.c
parenta2a23322193eeca5d2912c0b74c5374f8ec21737 (diff)
downloadlibgit2-3f8942052306a9d62521bdb6e6d5e7636bc5526e.tar.gz
remote: allow overriding the refspecs for download and fetch
With opportunistic ref updates, git has introduced the concept of having base refspecs *and* refspecs that are active for a particular fetch. Let's start by letting the user override the refspecs for download.
Diffstat (limited to 'tests/online/fetch.c')
-rw-r--r--tests/online/fetch.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/online/fetch.c b/tests/online/fetch.c
index f03a6faa6..ce92ee82b 100644
--- a/tests/online/fetch.c
+++ b/tests/online/fetch.c
@@ -47,7 +47,7 @@ static void do_fetch(const char *url, git_remote_autotag_option_t flag, int n)
git_remote_set_callbacks(remote, &callbacks);
git_remote_set_autotag(remote, flag);
cl_git_pass(git_remote_connect(remote, GIT_DIRECTION_FETCH));
- cl_git_pass(git_remote_download(remote));
+ cl_git_pass(git_remote_download(remote, NULL));
cl_git_pass(git_remote_update_tips(remote, NULL, NULL));
git_remote_disconnect(remote);
cl_assert_equal_i(counter, n);
@@ -86,11 +86,11 @@ void test_online_fetch__fetch_twice(void)
git_remote *remote;
cl_git_pass(git_remote_create(&remote, _repo, "test", "git://github.com/libgit2/TestGitRepository.git"));
cl_git_pass(git_remote_connect(remote, GIT_DIRECTION_FETCH));
- cl_git_pass(git_remote_download(remote));
+ cl_git_pass(git_remote_download(remote, NULL));
git_remote_disconnect(remote);
git_remote_connect(remote, GIT_DIRECTION_FETCH);
- cl_git_pass(git_remote_download(remote));
+ cl_git_pass(git_remote_download(remote, NULL));
git_remote_disconnect(remote);
git_remote_free(remote);
@@ -128,7 +128,7 @@ void test_online_fetch__doesnt_retrieve_a_pack_when_the_repository_is_up_to_date
callbacks.transfer_progress = &transferProgressCallback;
callbacks.payload = &invoked;
git_remote_set_callbacks(remote, &callbacks);
- cl_git_pass(git_remote_download(remote));
+ cl_git_pass(git_remote_download(remote, NULL));
cl_assert_equal_i(false, invoked);
@@ -162,7 +162,7 @@ void test_online_fetch__can_cancel(void)
git_remote_set_callbacks(remote, &callbacks);
cl_git_pass(git_remote_connect(remote, GIT_DIRECTION_FETCH));
- cl_git_fail_with(git_remote_download(remote), -4321);
+ cl_git_fail_with(git_remote_download(remote, NULL), -4321);
git_remote_disconnect(remote);
git_remote_free(remote);
}