diff options
author | Vicent Martà <tanoku@gmail.com> | 2012-05-18 03:21:06 +0400 |
---|---|---|
committer | Vicent Martà <tanoku@gmail.com> | 2012-05-18 03:26:26 +0400 |
commit | e172cf082e62aa421703080d0bccb7b8762c8bd4 (patch) | |
tree | c19f7b1be056a9176d4e865f5be5c69a5c2912c6 /tests-clar/revwalk | |
parent | 2e2e97858de18abd43f7e59fcc6151510c6d3272 (diff) |
errors: Rename the generic return codes
Diffstat (limited to 'tests-clar/revwalk')
-rw-r--r-- | tests-clar/revwalk/basic.c | 12 | ||||
-rw-r--r-- | tests-clar/revwalk/mergebase.c | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/tests-clar/revwalk/basic.c b/tests-clar/revwalk/basic.c index 7d54ce990..a5a9b2eda 100644 --- a/tests-clar/revwalk/basic.c +++ b/tests-clar/revwalk/basic.c @@ -73,7 +73,7 @@ static int test_walk(git_revwalk *walk, const git_oid *root, i = 0; - while (git_revwalk_next(&oid, walk) == GIT_SUCCESS) { + while (git_revwalk_next(&oid, walk) == 0) { result_array[i++] = get_commit_index(&oid); /*{ char str[41]; @@ -86,7 +86,7 @@ static int test_walk(git_revwalk *walk, const git_oid *root, for (i = 0; i < results_count; ++i) if (memcmp(possible_results[i], result_array, result_bytes) == 0) - return GIT_SUCCESS; + return 0; return GIT_ERROR; } @@ -125,7 +125,7 @@ void test_revwalk_basic__glob_heads(void) cl_git_pass(git_revwalk_push_glob(_walk, "heads")); - while (git_revwalk_next(&oid, _walk) == GIT_SUCCESS) { + while (git_revwalk_next(&oid, _walk) == 0) { i++; } @@ -140,7 +140,7 @@ void test_revwalk_basic__push_head(void) cl_git_pass(git_revwalk_push_head(_walk)); - while (git_revwalk_next(&oid, _walk) == GIT_SUCCESS) { + while (git_revwalk_next(&oid, _walk) == 0) { i++; } @@ -156,7 +156,7 @@ void test_revwalk_basic__push_head_hide_ref(void) cl_git_pass(git_revwalk_push_head(_walk)); cl_git_pass(git_revwalk_hide_ref(_walk, "refs/heads/packed-test")); - while (git_revwalk_next(&oid, _walk) == GIT_SUCCESS) { + while (git_revwalk_next(&oid, _walk) == 0) { i++; } @@ -172,7 +172,7 @@ void test_revwalk_basic__push_head_hide_ref_nobase(void) cl_git_pass(git_revwalk_push_head(_walk)); cl_git_pass(git_revwalk_hide_ref(_walk, "refs/heads/packed")); - while (git_revwalk_next(&oid, _walk) == GIT_SUCCESS) { + while (git_revwalk_next(&oid, _walk) == 0) { i++; } diff --git a/tests-clar/revwalk/mergebase.c b/tests-clar/revwalk/mergebase.c index e807e3ad2..694dffcba 100644 --- a/tests-clar/revwalk/mergebase.c +++ b/tests-clar/revwalk/mergebase.c @@ -63,7 +63,7 @@ void test_revwalk_mergebase__no_common_ancestor_returns_ENOTFOUND(void) error = git_merge_base(&result, _repo, &one, &two); cl_git_fail(error); - cl_assert_equal_i(GIT_ENOTFOUND, error); + cl_assert_equal_i(GIT_NOTFOUND, error); } /* |