diff options
| author | Carlos Martín Nieto <cmn@dwim.me> | 2013-04-20 19:13:47 +0200 |
|---|---|---|
| committer | Carlos Martín Nieto <cmn@dwim.me> | 2013-04-20 19:45:40 +0200 |
| commit | 1be680c4d0909ee5160292d7b56c4522c4bc309c (patch) | |
| tree | 605d1eeee4933f727219d8c8d7fd8fd23a09c133 /tests-clar/network/remote/remotes.c | |
| parent | bc6374eac485ab9ad9cfd7165b6d071c3dcb673a (diff) | |
| download | libgit2-1be680c4d0909ee5160292d7b56c4522c4bc309c.tar.gz | |
refspec: unify the string and parsed data
It used to be separate as an attempt to make the querying easier, but
it didn't work out that way, so put all the data together.
Add git_refspec_string() as well to get the original string, which is
now stored alongside the independent parts.
Diffstat (limited to 'tests-clar/network/remote/remotes.c')
| -rw-r--r-- | tests-clar/network/remote/remotes.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests-clar/network/remote/remotes.c b/tests-clar/network/remote/remotes.c index 7b6e6aa85..908e17d96 100644 --- a/tests-clar/network/remote/remotes.c +++ b/tests-clar/network/remote/remotes.c @@ -114,17 +114,17 @@ void test_network_remote_remotes__add_fetchspec(void) size_t size; size = _remote->refspecs.length; - cl_assert_equal_i(size, _remote->refspec_strings.length); + cl_assert_equal_i(size, _remote->refspecs.length); cl_git_pass(git_remote_add_fetch(_remote, "refs/*:refs/*")); size++; - cl_assert_equal_i(size, _remote->refspec_strings.length); cl_assert_equal_i(size, _remote->refspecs.length); _refspec = git_vector_get(&_remote->refspecs, size-1); cl_assert_equal_s(git_refspec_src(_refspec), "refs/*"); cl_assert_equal_s(git_refspec_dst(_refspec), "refs/*"); + cl_assert_equal_s(git_refspec_string(_refspec), "refs/*:refs/*"); cl_assert_equal_i(_refspec->push, false); } @@ -136,12 +136,12 @@ void test_network_remote_remotes__add_pushspec(void) cl_git_pass(git_remote_add_push(_remote, "refs/*:refs/*")); size++; - cl_assert_equal_i(size, _remote->refspec_strings.length); cl_assert_equal_i(size, _remote->refspecs.length); _refspec = git_vector_get(&_remote->refspecs, size-1); cl_assert_equal_s(git_refspec_src(_refspec), "refs/*"); cl_assert_equal_s(git_refspec_dst(_refspec), "refs/*"); + cl_assert_equal_s(git_refspec_string(_refspec), "refs/*:refs/*"); cl_assert_equal_i(_refspec->push, true); } |
