tests-clar/refs


Log

Author Commit Date CI Message
Vicent Martí 9afc5971 2013-05-31T03:09:38 Merge pull request #1559 from carlosmn/ref-shorthand Introduce git_reference_shorthand
nulltoken f672cd2a 2013-05-10T20:15:57 revparse: Make revparse_ext() return git_reference from names as well
nulltoken e841c533 2013-05-09T16:42:39 revparse: Introduce git_revparse_ext() Expose a way to retrieve, along with the target git_object, the reference pointed at by some revparse expression (`@{<-n>}` or `<branchname>@{upstream}` syntax).
nulltoken 1fed6b07 2013-05-13T21:57:37 Fix trailing whitespaces
Russell Belfer 99d32707 2013-05-11T06:42:25 Fix refdb iteration early termination bug There was a problem found in the Rugged test suite where the refdb_fs_backend__next function could exit too early in some very specific hashing patterns for packed refs. This ports the Rugged test to libgit2 and then fixes the bug.
Edward Thomson b6cc559a 2013-05-11T02:42:49 Merge pull request #1385 from carlosmn/refs-iter Introduce a refs iterator
Carlos Martín Nieto 2b562c3a 2013-05-04T16:32:58 refs: remove the OID/SYMBOLIC filtering Nobody should ever be using anything other than ALL at this level, so remove the option altogether. As part of this, git_reference_foreach_glob is now implemented in the frontend using an iterator. Backends will later regain the ability of doing the glob filtering in the backend.
Carlos Martín Nieto fb592a96 2013-05-04T15:54:57 Remove outdated test Selecting wether to list loose or packed references is not something we want to support anymore, so remove a test for this.
Carlos Martín Nieto 51fc5e89 2013-05-04T15:16:55 Make sure the ref iterator works in an repo without physical presence
Carlos Martín Nieto 4def7035 2013-03-02T19:31:03 refs: introduce an iterator This allows us to get a list of reference names in a loop instead of callbacks.
nulltoken 24988894 2013-05-10T12:02:17 Fix some memory leaks
Carlos Martín Nieto 4f2eb2b7 2013-05-08T02:28:47 Introduce git_reference_shorthand Generate a shorthand name out of the full refname.
Nikolai Vladimirov 3d42e9a3 2013-05-06T20:32:20 git_branch_set_upstream with local branches Currently git_branch_set_upstream when passed a local branch creates invalid configuration, for ex. if we setup branch 'tracking_master' to track local 'master' libgit2 generates the following config ``` [branch "track_master"] remote = . merge = .refs/heads/track_master ``` The merge value is invalid and calling git_branch_upstream on 'tracking_master' results in invalid reference error. It should do: ``` [branch "track_master"] remote = . merge = refs/heads/master ```
Vicent Martí 03c28d92 2013-05-06T06:45:53 Merge pull request #1526 from arrbee/cleanup-error-return-without-msg Make sure error messages are set for most error returns
Jeff King 7edb9071 2013-05-02T11:07:20 refdb_fs: do not require peeled packed refs to be tags Older versions of git would only write peeled entries for items under refs/tags/. Newer versions will write them for all refs, and we should be prepared to handle that.
Russell Belfer 3e199f42 2013-05-01T04:18:46 Set error message for branch functions There were a couple of places where an error was being returned from branch related code but no error message was being set.
Carlos Martín Nieto bc6374ea 2013-04-20T18:49:11 remote: allow querying for refspecs Introduce git_remote_{fetch,push}_refspecs() to get a list of refspecs from the remote and rename the refspec-adding functions to a less silly name. Use this instead of the vector index hacks in the tests.
Carlos Martín Nieto 4330ab26 2013-04-20T04:43:28 remote: handle multiple refspecs A remote can have a multitude of refspecs. Up to now our git_remote's have supported a single one for each fetch and push out of simplicity to get something working. Let the remotes and internal code know about multiple remotes and get the tests passing with them. Instead of setting a refspec, the external users can clear all and add refspecs. This should be enough for most uses, though we're still missing a querying function.
Edward Thomson 4e4eab52 2013-04-19T18:19:53 alloc doesn't take a refdb; git_refdb_free nicely in the tests
Vicent Marti cbda09d0 2013-04-15T23:40:46 git_revision -> git_revspec
Vicent Marti 36c2dfed 2013-04-15T23:32:40 Is this crazy?
Vicent Marti d064c747 2013-04-15T23:18:24 Merge remote-tracking branch 'ben/unified-revparse' into development
Ben Straub 299a224b 2013-04-15T12:00:04 Change git_revparse to output git_object pointers This will probably prevent many lookup/free operations in calling code.
Ben Straub 2ebc3c66 2013-04-15T11:57:24 Redeploy git_revparse_single.
Vicent Martí ea8bac37 2013-04-11T06:34:59 Merge pull request #1450 from carlosmn/branch-upstream Branch upstream configuration
Carlos Martín Nieto d59942c2 2013-03-30T04:27:42 branch: add more upstream configuration management Add functions to set and unset the upstream configuration to complement the getter we already have.
Ben Straub 1aa21fe3 2013-04-09T05:03:51 Deprecate git_revparse_single and _rangelike
Ben Straub 8480eef7 2013-03-11T20:27:16 Implement unified git_revparse
Vicent Marti 812e5aea 2013-04-07T07:23:08 test: Add missing NULLs
Vicent Marti d9ecaf8c 2013-04-07T07:22:38 Merge remote-tracking branch 'gnprice/revwalk' into development
Greg Price b208d900 2013-03-20T10:01:58 revparse: Parse range-like syntax Signed-off-by: Greg Price <price@mit.edu>
nulltoken 24cb87e2 2013-03-31T13:27:43 tag: Fix parsing when no tagger nor message
Carlos Martín Nieto 97016f29 2013-03-30T09:30:29 branch: refactor git_branch_remote_name Return the size we'd need to write to instead of simply an error. Split the function into two to be used later by the upstream configuration functions.
Carlos Martín Nieto a258d8e3 2013-03-30T03:39:19 branch: rename 'tracking' to 'upstream' The term 'tracking' is overloaded. Help distinguish what we mean by using 'upstream' for this part of the library.
Russell Belfer 55e0f53d 2013-03-14T15:09:29 Fix various build warnings This fixes various build warnings on Mac and Windows (64-bit).
Edward Thomson d00d5464 2013-03-01T15:37:33 immutable references and a pluggable ref database
Carlos Martín Nieto bb45c57f 2013-03-07T16:38:44 refs: explicitly catch leading slashes It's somewhat common to try to write "/refs/tags/something". There is no easy way to catch it during the main body of the function, as there is no way to distinguish whether it's a leading slash or a double slash somewhere in the middle. Catch this at the beginning so we don't trigger the assert in is_all_caps_and_underscore().
Russell Belfer 0d1b094b 2013-02-26T13:15:06 Fix portability issues on Windows The new tests were not taking core.filemode into account when testing file modes after repo initialization. Fixed that and some other Windows warnings that have crept in.
nulltoken bbc53e4f 2013-02-15T12:43:03 branch: refactor git_branch_remote_name() tests
nulltoken c1b5e8c4 2013-02-15T11:35:33 branch: Make git_branch_remote_name() cope with orphaned heads
nulltoken 2bca5b67 2013-02-07T23:44:18 remote: Introduce git_remote_is_valid_name() Fix libgit2/libgit2sharp#318
nulltoken 4d811c3b 2013-02-07T23:40:10 refs: No component of a refname can end with '.lock'
Russell Belfer 390a3c81 2013-02-11T11:44:00 Merge pull request #1190 from nulltoken/topic/reset-paths reset: Allow the selective reset of pathspecs
Philip Kelley e026cfee 2013-02-11T09:12:39 Merge pull request #1323 from jamill/resolve_remote Resolve a remote branch's remote
Jameson Miller 2e3e8c88 2013-02-08T11:05:47 Teach remote branch to return its remote
Scott J. Goldman 6ce61a0b 2013-02-08T14:25:41 tests: fix whitespace in refs/rename.c
nulltoken 3ad05221 2013-02-05T16:52:56 Fix MSVC compilation warnings Fix #1308
nulltoken 0e8e5a61 2013-02-03T11:44:26 revparse: Lookup sha before branch
nulltoken 545b479a 2013-02-02T17:36:20 revparse: Lookup branch before described tag Fix #1306
Carlos Martín Nieto e5ef0f18 2013-01-31T20:23:30 refs: handle ALLOW_ONELEVEL normalization with leading slash A leading slash confuses the name normalization code when the flags include ALLOW_ONELEVEL. Catch this case in particular to avoid triggering an assertion in the uppercase check which expects us not to pass it an empty string. The existing tests don't catch this as they simply use the NORMAL flag. This fixes #1300.
Sebastian Bauer a7f8065f 2013-01-25T06:48:55 Use cl_assert_equal_s() instead of strcmp(). Replaced all cl_assert(!strcmp()) or semantically equivalent forms by cl_assert_equal_s().
Sebastian Bauer c253056d 2013-01-24T20:44:17 Added git_branch_name(). This is a convenience function to get the branch name of a given ref. The returned branch name is compatible with the name that can be supplied e.g. to git_branch_lookup(). That is, the prefixes "refs/heads" or "refs/remotes" are omitted. Also added a new test for testing the new function.
Scott J. Goldman 5c7b77c4 2013-01-22T16:01:03 Seperate out a new test that verifies packed-refs with no trailing newline as per @vmg's request
nulltoken bf031581 2013-01-14T14:22:11 branch: Introduce git_branch_tracking_name()
Martin Woodward ba1a430a 2013-01-04T17:29:45 Add jGit license block to derrived tests Add the jGit license block to tests derrived from jGit as per the terms of the BSD license.
Ben Straub 72629a10 2012-12-10T10:05:31 Clean up GCC build warnings
Vicent Martí e05ca13f 2012-12-05T11:47:19 Merge pull request #1115 from ben/struct-versions Version info for public structs
nulltoken cc146626 2012-11-19T19:00:46 revparse: Deploy EINVALIDSPEC usage
nulltoken 84166fac 2012-11-18T14:20:35 revparse: remove timezone setup in tests
nulltoken bc05f30c 2012-11-19T18:49:25 object: refine git_object_peel() error report
nulltoken 62173038 2012-11-12T20:47:32 branch: Deploy EINVALIDSPEC usage
nulltoken 80212ecb 2012-11-12T16:49:29 reflog: Deploy EINVALIDSPEC usage
nulltoken e4aa7f58 2012-11-12T17:25:55 refs: cover git_reference_name_to_oid() unfound behavior
nulltoken 80d9d1df 2012-11-12T15:42:15 refs: Deploy EINVALIDSPEC usage
nulltoken 47261d9c 2012-11-12T14:19:37 tests: drop unused variables
nulltoken 3da73c40 2012-11-29T21:33:31 Fix compilation warnings
Ben Straub f4fc9fdb 2012-11-29T12:26:40 Cleanup nitpicky things
nulltoken 37849a8e 2012-11-17T22:09:55 tracking: fix retrieval of the tracking ref of branch with empty merge and/or remote entry
nulltoken f1bd50d6 2012-11-17T22:07:30 tracking: remove code duplication in test
Ben Straub cb7ac81c 2012-11-27T13:30:04 Fix warning
Russell Belfer a8122b5d 2012-11-21T15:39:03 Fix warnings on Win64 build
Vicent Marti cfbe4be3 2012-11-17T19:54:47 More external API cleanup Conflicts: src/branch.c tests-clar/refs/branches/create.c
Ben Straub 2508cc66 2012-11-18T21:38:08 Rename ref and reflog apis for consistency
Sascha Cunz 9094d30b 2012-11-23T11:41:56 Reset all static variables to NULL in clar's __cleanup Without this change, any failed assertion in the second (or a later) test inside a test suite has a chance of double deleting memory, resulting in a heap corruption. See #1096 for details. This leaves alone the test cases where we "just" use cl_git_sandbox_init() and cl_git_sandbox_cleanup(). These methods already take good care to not double delete a repository. Fixes #1096
nulltoken b15df1d9 2012-11-17T18:29:51 reflog: make entry_byindex() and drop() git compliant Passing 0 as the index now retrieves the most recent entry instead of the oldest one.
nulltoken b1a3a70e 2012-11-12T00:14:51 repository: Refine repository_head() error report
nulltoken 1f87fa35 2012-10-09T18:29:26 reflog: fix bogus removal of reflog entries
nulltoken 383f164a 2012-09-07T17:55:30 branch: rename config section upon moving
nulltoken 0b98a8a4 2012-09-07T15:13:11 branch: remove config section upon deletion
nulltoken cd1ef822 2012-10-20T12:07:53 test: extract make_head_orphaned() logic
nulltoken 209e34fa 2012-10-20T10:44:01 tests: leverage git_repository_detach_head()
nulltoken 8b05bea8 2012-10-19T17:07:39 errors: deploy GIT_EORPHANEDHEAD usage
nulltoken 0532e7bb 2012-10-19T20:34:33 branch: allow deletion of branch when HEAD's missing
nulltoken 2df37f42 2012-10-18T23:59:22 refs: cover more refname validity edge cases
nulltoken 5912d74c 2012-10-18T22:25:27 revparse: properly handle refnames containing a @ Fix #994
Carlos Martín Nieto 7ae5ab56 2012-10-15T16:35:10 Fix leak in the tests Also introduce the slective ref trimming promised but also missed in the previous commit.
Carlos Martín Nieto 47f44b6e 2012-10-15T13:51:25 refs: loosen the OID parsing We used to require loose references to contain only an OID (possibly after trimming the string). This is however not enough for letting us lookup FETCH_HEAD, which can have a lot of content after the initial OID. Change the parsing rules so that a loose refernce must e at least 40 bytes long and the 41st (if it's there) must be accepted by isspace(3). This makes the trim unnecessary, so only do it for symrefs. This fixes #977.
nulltoken 6251de1d 2012-10-11T14:09:27 branches: cover EEXISTS propagation upon moving
nulltoken 62993b61 2012-10-11T14:08:32 branches: propagate EEXISTS upon creation
nulltoken 3548fcf5 2012-10-11T14:00:26 refs: propagate EEXISTS upon renaming
nulltoken 0c78f685 2012-10-06T10:41:53 branch: introduce git_branch_is_head()
nulltoken b52b6571 2012-09-22T12:42:16 branch: enhance branch moving test coverage
Carlos Martín Nieto c1281493 2012-09-30T11:37:53 refs: propagate EEXISTS Indicate whether the error comes from the ref already existing or elsewhere. We always perform the check and this lets the user write more concise code.
Vicent Martí 31d22037 2012-09-25T14:52:24 Merge pull request #944 from scunz/list_tags Tags: teach git_tag_list not to include the 'refs/tags/' prefix
nulltoken 77e06d7e 2012-09-17T07:11:32 refs: introduce git_reference_is_valid_name()
nulltoken c030ada7 2012-09-11T12:06:57 refs: make git_reference_normalize_name() accept refspec pattern
Sascha Cunz 7604ddbf 2012-09-21T00:57:21 Tests: Add 3 tags to resources/testrepo. Adjusts refs::list test (including the comments) Adjusts objects::tags::list test
nulltoken c2948c77 2012-09-14T21:36:49 refs: prevent locked refs from being enumerated Fix #936
nulltoken e16fc07f 2012-09-13T22:22:40 refspec: No remote tracking ref from a fetchspec-less remote
nulltoken 31665948 2012-08-24T21:30:45 refs: introduce git_reference_peel() Fix #530