summaryrefslogtreecommitdiff
path: root/tests-clar/checkout/tree.c
Commit message (Collapse)AuthorAgeFilesLines
* Rename tests-clar to testsBen Straub2013-11-141-742/+0
|
* Prevent checkout_tree when conflicts exist, clear NAME on checkout treeEdward Thomson2013-10-161-0/+44
| | | | | | | Prevent checkout tree when unresolved changes exist (unless FORCE flag is specified). Clear NAME table when checking out, to avoid checkout_conflicts from attempting to manipulate it. Ensure that NAME is also cleared at reset.
* Add checkout test for long file nameBen Straub2013-08-071-0/+19
|
* Fix checkout tests on WindowsRussell Belfer2013-06-241-3/+6
|
* Addition checkout target directory testsRussell Belfer2013-06-211-0/+44
| | | | | This adds additonal tests of the checkout target directory option including using it to dump data from bare repos.
* Fix checkout of modified file when missing from wdRussell Belfer2013-06-211-0/+11
| | | | | | | | | | This fixes the checkout case when a file is modified between the baseline and the target and yet missing in the working directory. The logic for that case appears to have been wrong. This also adds a useful checkout notify callback to the checkout test helpers that will count notifications and also has a debug mode to visualize what checkout thinks that it's doing.
* test asserting checkout should not recreate deleted filesEdward Thomson2013-06-201-0/+30
|
* Fix trailing whitespacesnulltoken2013-05-151-1/+1
|
* allow checkout to proceed when a dir to be removed is in use (win32)Edward Thomson2013-05-031-0/+63
|
* allow empty dirs to exist when doing checkoutEdward Thomson2013-05-011-0/+25
|
* Redeploy git_revparse_single.Ben Straub2013-04-151-40/+13
|
* Deprecate git_revparse_single and _rangelikeBen Straub2013-04-091-13/+37
|
* Fix up checkout file contents checksRussell Belfer2013-03-251-3/+3
| | | | | | | | | | | | This fixes of the file contents checks in checkout to give slightly better error messages by directly calling the underlying clar assertions so the file and line number of the top level call can be reported correctly, and renames the helpers to not start with "test_" since that is kind of reserved by clar. This also enables some of the CRLF tests on all platforms that were previously Windows only (by pushing a check of the native line endings into the test body).
* Test fixes and cleanupRussell Belfer2013-03-251-18/+7
| | | | | | | | This fixes some places where the new tests were leaving the test area in a bad state or were freeing data they should not free. It also removes code that is extraneous to the core issue and fixes an invalid SHA being looked up in one of the tests (which was failing, but for the wrong reason).
* Added some tests for issue #1397Sven Strickroth2013-03-251-0/+34
| | | | Signed-off-by: Sven Strickroth <email@cs-ware.de>
* Add cl_repo_set_bool and cleanup testsRussell Belfer2013-03-221-11/+10
| | | | | | This adds a helper function for the cases where you want to quickly set a single boolean config value for a repository. This allowed me to remove a lot of code.
* don't dereference at the end of the workdir iteratorEdward Thomson2013-02-271-0/+38
|
* Merge pull request #1239 from ethomson/index_removeVicent Martí2013-01-171-1/+1
|\ | | | | add an index_remove_bypath that removes conflicts
| * add an index_remove_bypath that removes conflicts, renamed add_from_workdir ↵Edward Thomson2013-01-121-1/+1
| | | | | | | | to match
* | Fix Travis compilation warningsnulltoken2013-01-131-3/+2
| |
* | tests: plug leaksCarlos Martín Nieto2013-01-121-0/+3
|/
* checkout: Deploy EMERGECONFLICT usagenulltoken2013-01-111-0/+86
|
* Fix indentationsnulltoken2013-01-111-20/+20
|
* Add GIT_CHECKOUT_DISABLE_PATHSPEC_MATCHRussell Belfer2013-01-101-0/+83
| | | | | | | This adds an option to checkout a la the diff option to turn off fnmatch evaluation for pathspec entries. This can be useful to make sure your "pattern" in really interpretted as an exact file match only.
* tests: Fix some memory leaksnulltoken2013-01-061-0/+6
|
* Fix crlf issue with checkout testsRussell Belfer2013-01-041-41/+3
| | | | | Move some checkout utility functions into a shared file and fix some crlf filtering issues when verifying file contents.
* Fixing checkout UPDATE_ONLY and adding testsRussell Belfer2013-01-041-0/+171
| | | | | This adds a bunch of new checkout tests and in the process I found a bug in the GIT_CHECKOUT_UPDATE_ONLY flag which I fixed.
* Add index updating to checkoutRussell Belfer2013-01-041-11/+12
| | | | | | | Make checkout update entries in the index for all files that are updated and/or removed, unless flag GIT_CHECKOUT_DONT_UPDATE_INDEX is given. To do this, iterators were extended to allow a little more introspection into the index being iterated over, etc.
* More checkout improvementsRussell Belfer2013-01-041-3/+4
| | | | | | | This flips checkout back to be driven off the changes between the baseline and the target trees. This reinstates the complex code for tracking the contents of the working directory, but overall, I think the resulting logic is easier to follow.
* Rework checkout internals (again)Russell Belfer2013-01-041-1/+1
| | | | | | | | | | | | | | | | I've tried to map out the detailed behaviors of checkout and make sure that we're handling the various cases correctly, along with providing options to allow us to emulate "git checkout" and "git checkout-index" with the various flags. I've thrown away flags in the checkout API that seemed like clutter and added some new ones. Also, I've converted the conflict callback to a general notification callback so we can emulate "git checkout" output and display "dirty" files. As of this commit, the new behavior is not working 100% but some of that is probably baked into tests that are not testing the right thing. This is a decent snapshot point, I think, along the way to getting the update done.
* Failing test on git_checkout_tree when removing directoriesJameson Miller2013-01-041-0/+27
|
* Add failing test to demonstrate wrong checkout behaviourMarvin Gülker2013-01-041-0/+20
|
* Deploy GIT_INIT_STRUCTUREBen Straub2012-11-301-2/+1
|
* Deploy GIT_CHECKOUT_OPTS_INITBen Straub2012-11-301-1/+2
|
* Reset all static variables to NULL in clar's __cleanupSascha Cunz2012-11-231-0/+1
| | | | | | | | | | | | 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
* Rework checkout with new strategy optionsRussell Belfer2012-11-091-1/+4
| | | | | | | | | | | | | | | | | | This is a major reworking of checkout strategy options. The checkout code is now sensitive to the contents of the HEAD tree and the new options allow you to update the working tree so that it will match the index content only when it previously matched the contents of the HEAD. This allows you to, for example, to distinguish between removing files that are in the HEAD but not in the index, vs just removing all untracked files. Because of various corner cases that arise, etc., this required some additional capabilities in rmdir and other utility functions. This includes the beginnings of an implementation of code to read a partial tree into the index based on a pathspec, but that is not enabled because of the possibility of creating conflicting index entries.
* Fix Windows buildBen Straub2012-10-251-1/+1
| | | | Pedantic ordering of GIT_UNUSED vs. variable declarations.
* Checkout progress now reports completed/total stepsBen Straub2012-10-191-2/+2
|
* Fix broken testsBen Straub2012-10-191-5/+5
|
* Convert checkout_* to use progress callbackBen Straub2012-10-191-3/+21
|
* checkout: Mimic git_diff_options storage of pathsnulltoken2012-09-171-8/+4
|
* checkout: add test coverage of dirs and subtreesnulltoken2012-09-171-6/+46
|
* checkout: separate tree from index related testsnulltoken2012-09-171-239/+0
|
* checkout: introduce git_checkout_tree()nulltoken2012-09-171-0/+268