diff options
author | Russell Belfer <rb@github.com> | 2012-11-13 13:58:29 -0800 |
---|---|---|
committer | Russell Belfer <rb@github.com> | 2012-11-14 22:54:31 -0800 |
commit | 5735bf5e6ab4da347b601d4b85c09c5c701dc002 (patch) | |
tree | a6a33b5234bba3ba293af13c91e435213a4223c5 /tests-clar/diff/diffiter.c | |
parent | 5a36f127808c7b470eef17b1a8a130dde0cc64a1 (diff) | |
download | libgit2-5735bf5e6ab4da347b601d4b85c09c5c701dc002.tar.gz |
Fix diff API to better parameter order
The diff API is not in the parameter order one would expect from
other libgit2 APIs. This fixes that.
Diffstat (limited to 'tests-clar/diff/diffiter.c')
-rw-r--r-- | tests-clar/diff/diffiter.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/tests-clar/diff/diffiter.c b/tests-clar/diff/diffiter.c index 86e8d1f57..f021d46f4 100644 --- a/tests-clar/diff/diffiter.c +++ b/tests-clar/diff/diffiter.c @@ -16,7 +16,7 @@ void test_diff_diffiter__create(void) git_diff_list *diff; size_t d, num_d; - cl_git_pass(git_diff_workdir_to_index(repo, NULL, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, NULL)); num_d = git_diff_num_deltas(diff); for (d = 0; d < num_d; ++d) { @@ -34,7 +34,7 @@ void test_diff_diffiter__iterate_files(void) size_t d, num_d; int count = 0; - cl_git_pass(git_diff_workdir_to_index(repo, NULL, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, NULL)); num_d = git_diff_num_deltas(diff); cl_assert_equal_i(6, (int)num_d); @@ -57,7 +57,7 @@ void test_diff_diffiter__iterate_files_2(void) size_t d, num_d; int count = 0; - cl_git_pass(git_diff_workdir_to_index(repo, NULL, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, NULL)); num_d = git_diff_num_deltas(diff); cl_assert_equal_i(8, (int)num_d); @@ -85,7 +85,7 @@ void test_diff_diffiter__iterate_files_and_hunks(void) opts.interhunk_lines = 1; opts.flags |= GIT_DIFF_INCLUDE_IGNORED | GIT_DIFF_INCLUDE_UNTRACKED; - cl_git_pass(git_diff_workdir_to_index(repo, &opts, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, &opts)); num_d = git_diff_num_deltas(diff); @@ -138,7 +138,7 @@ void test_diff_diffiter__max_size_threshold(void) opts.interhunk_lines = 1; opts.flags |= GIT_DIFF_INCLUDE_IGNORED | GIT_DIFF_INCLUDE_UNTRACKED; - cl_git_pass(git_diff_workdir_to_index(repo, &opts, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, &opts)); num_d = git_diff_num_deltas(diff); for (d = 0; d < num_d; ++d) { @@ -173,7 +173,7 @@ void test_diff_diffiter__max_size_threshold(void) opts.flags |= GIT_DIFF_INCLUDE_IGNORED | GIT_DIFF_INCLUDE_UNTRACKED; opts.max_size = 50; /* treat anything over 50 bytes as binary! */ - cl_git_pass(git_diff_workdir_to_index(repo, &opts, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, &opts)); num_d = git_diff_num_deltas(diff); for (d = 0; d < num_d; ++d) { @@ -216,7 +216,7 @@ void test_diff_diffiter__iterate_all(void) opts.interhunk_lines = 1; opts.flags |= GIT_DIFF_INCLUDE_IGNORED | GIT_DIFF_INCLUDE_UNTRACKED; - cl_git_pass(git_diff_workdir_to_index(repo, &opts, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, &opts)); num_d = git_diff_num_deltas(diff); for (d = 0; d < num_d; ++d) { @@ -292,7 +292,7 @@ void test_diff_diffiter__iterate_randomly_while_saving_state(void) opts.interhunk_lines = 1; opts.flags |= GIT_DIFF_INCLUDE_IGNORED | GIT_DIFF_INCLUDE_UNTRACKED; - cl_git_pass(git_diff_workdir_to_index(repo, &opts, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, &opts)); num_d = git_diff_num_deltas(diff); @@ -419,7 +419,7 @@ void test_diff_diffiter__iterate_and_generate_patch_text(void) git_diff_list *diff; size_t d, num_d; - cl_git_pass(git_diff_workdir_to_index(repo, NULL, &diff)); + cl_git_pass(git_diff_workdir_to_index(&diff, repo, NULL)); num_d = git_diff_num_deltas(diff); cl_assert_equal_i(8, (int)num_d); |