|
72c28ab0
|
2017-06-07T10:59:03
|
|
tests: status::worktree: indicate skipped tests on Win32
Some function bodies of tests which are not applicable to the Win32
platform are completely #ifdef'd out instead of calling `cl_skip()`.
This leaves us with no indication that these tests are not being
executed at all and may thus cause decreased scrutiny when investigating
skipped tests. Improve the situation by calling `cl_skip()` instead of
just doing nothing.
|
|
09c15a7f
|
2017-10-09T09:08:19
|
|
tests: checkout::tree: check that the status list catches mode changes
While we verify that we have no mode changes after calling
`git_checkout_tree`, we do not verify that the `p_chmod` calls actually
resulted in a changed entry. While we should assume that this works due
to separate tests for the status list, we should test for the change
being listed to avoid programming errors in the test.
|
|
880dfc50
|
2017-10-09T09:06:24
|
|
tests: checkout::tree: extract check for status entrycount
There are multiple locations where we have the same code to check
whether the count of status list entries of a repository matches an
expected number. Extract that into a common function.
|
|
19e8faba
|
2016-06-15T01:59:56
|
|
checkout: test force checkout when mode changes
Test that we can successfully force checkout a target when the file
contents are identical, but the mode has changed.
|
|
1f813cf2
|
2017-01-23T17:32:13
|
|
checkout::tree test: cleanup memory leak
|
|
5f959dca
|
2016-12-29T19:26:50
|
|
Fix handling of GIT_CHECKOUT_DISABLE_PATHSPEC_MATCH flag.
git_checkout_tree() sets up its working directory iterator to respect the
pathlist if GIT_CHECKOUT_DISABLE_PATHSPEC_MATCH is present, which is great.
What's not so great is that this iterator is then used side-by-side with
an iterator created by git_checkout_iterator(), which did not set up its
pathlist appropriately (although the iterator mirrors all other iterator
options).
This could cause git_checkout_tree() to delete working tree files which
were not specified in the pathlist when GIT_CHECKOUT_DISABLE_PATHSPEC_MATCH
was used, as the unsynchronized iterators causes git_checkout_tree() to think
that files have been deleted between the two trees. Oops.
And added a test which fails without this fix (specifically, the final check
for "testrepo/README" to still be present fails).
|
|
88cfe614
|
2016-08-24T01:20:39
|
|
git_checkout_tree options fix
According to the reference the git_checkout_tree and git_checkout_head
functions should accept NULL in the opts field
This was broken since the opts field was dereferenced and thus lead to a
crash.
|
|
bb0bd71a
|
2016-06-15T15:47:28
|
|
checkout: use empty baseline when no index
When no index file exists and a baseline is not explicitly provided, use
an empty baseline instead of trying to load `HEAD`.
|
|
eea7c850
|
2015-09-16T05:44:27
|
|
checkout: overwrite files with differing modes
When a file exists on disk and we're checking out a file that differs
in executableness, remove the old file. This allows us to recreate the
new file with p_open, which will take the new mode into account and
handle setting the umask properly.
Remove any notion of chmod'ing existing files, since it is now handled
by the aforementioned removal and was incorrect, as it did not take
umask into account.
|
|
6fe32284
|
2015-09-16T10:17:54
|
|
checkout::tree tests: don't use hardcoded mode
|
|
b4d183a7
|
2015-09-16T04:12:47
|
|
checkout::tree tests: don't use static buffer
|
|
33cad995
|
2015-06-01T14:31:49
|
|
Check that checkout preserves filemode in working directory.
|
|
6124d983
|
2015-06-01T11:16:36
|
|
Check that an executable in index is not an executable after checkout.
|
|
885b94aa
|
2015-05-28T15:26:13
|
|
Rename GIT_EMERGECONFLICT to GIT_ECONFLICT
We do not error on "merge conflicts"; on the contrary, merge conflicts
are a normal part of merging. We only error on "checkout conflicts",
where a change exists in the index or the working directory that would
otherwise be overwritten by performing the checkout.
This *may* happen during merge (after the production of the new index
that we're going to checkout) but it could happen during any checkout.
|
|
2f1080ea
|
2015-05-19T11:17:07
|
|
conflict tests: use GIT_IDXENTRY_STAGE_SET
|
|
64842d87
|
2015-04-23T09:21:33
|
|
checkout test: only run icase on icase platform
|
|
3520c970
|
2015-03-27T15:39:28
|
|
Revert "Always checkout with case sensitive iterator"
This reverts commit 40d791545abfb3cb71553a27dc64129e1a9bec28.
|
|
6dfd8506
|
2015-04-01T15:23:37
|
|
checkout test: ensure we write to casechanged dir
Ensure that on a case insensitive filesystem that we can checkout
into some folder 'FOLDER' that exists on disk, even if the target
of the checkout is a different case (eg 'folder').
|
|
431f9807
|
2015-03-27T15:33:44
|
|
checkout test: ignore unstaged case-changing renames
On Windows, you might sloppily rewrite a file (or have a sloppy
text editor that does it for you) and accidentally change its
case. (eg, "README" -> "readme"). Git ignores this accidental
case changing rename during checkout and will happily write the
new content to the file despite the name change. We should, too.
|
|
67db2bde
|
2015-03-10T12:02:45
|
|
Fix git_checkout_tree() to do index filemodes correctly on Windows.
git_checkout_tree() has some fallback behaviors for file systems
which don't have full support of filemodes. Generally works fine,
but if a given file had a change of type from a 0644 to 0755 (i.e.,
you add executable permissions), the fallback behavior incorrectly
triggers when writing hte updated index.
This would cause a git_checkout_tree() command, even with the
GIT_CHECKOUT_FORCE option set, to leave a dirty index on Windows.
Also added checks to an existing test to catch this case.
|
|
4e498646
|
2015-01-15T16:50:31
|
|
repository: remove log message override for switching the active branch
We want to use the "checkout: moving from ..." message in order to let
git know when a change of branch has happened. Make the convenience
functions for this goal write this message.
|
|
6bfb990d
|
2015-01-07T14:47:02
|
|
branch: don't accept a reflog message override
This namespace is about behaving like git's branch command, so let's do
exactly that instead of taking a reflog message.
This override is still available via the reference namespace.
|
|
23a17803
|
2015-01-07T14:16:50
|
|
reset: remove reflog message override
This function is meant to simulate what git does in the reset command,
so we should include the reflog message in that.
|
|
659cf202
|
2015-01-07T12:23:05
|
|
Remove the signature from ref-modifying functions
The signature for the reflog is not something which changes
dynamically. Almost all uses will be NULL, since we want for the
repository's default identity to be used, making it noise.
In order to allow for changing the identity, we instead provide
git_repository_set_ident() and git_repository_ident() which allow a user
to override the choice of signature.
|
|
496b76d4
|
2015-02-27T11:02:37
|
|
checkout tests: just use SAFE where appropriate
|
|
96b82b11
|
2015-02-14T11:44:05
|
|
checkout: remove `GIT_CHECKOUT_SAFE_CREATE` as a strategy
|
|
e6da3e44
|
2015-02-14T10:33:06
|
|
checkout: upgrade to `SAFE_CREATE` when no index file
When the repository does not contain an index, emulate git's behavior
and upgrade to `SAFE_CREATE`. This allows us to check out repositories
created with `git clone --no-checkout`.
|
|
8639ea5f
|
2015-01-17T22:47:03
|
|
checkout: introduce GIT_CHECKOUT_DONT_WRITE_INDEX
|
|
fa89ff20
|
2015-02-03T05:35:24
|
|
remove some unused warnings
|
|
2fbce0bf
|
2015-02-02T22:18:38
|
|
checkout test: ensure .gitattributes lifecycle
The .gitattributes cache should not reload .gitattributes in the
middle of checking out, only between checkout operations. Otherwise,
we'll spend all our time stat'ing and read'ing the gitattributes.
|
|
1d50b364
|
2015-01-12T16:16:27
|
|
checkout: introduce git_checkout_perfdata
Checkout can now provide performance data about the number of (some)
syscalls performed using an optional callback.
|
|
c4a2fd5c
|
2015-01-04T17:39:43
|
|
Plug a couple of leaks
|
|
40d79154
|
2014-05-09T19:32:52
|
|
Always checkout with case sensitive iterator
On a case-insensitive filesystem, we need to deal with case-changing
renames (eg, foo -> FOO) by removing the old and adding the new,
exactly as if we were on a case-sensitive filesystem.
Update the `checkout::tree::can_cancel_checkout_from_notify` test, now
that notifications are always sent case sensitively.
|
|
61ee5b0e
|
2014-05-08T17:35:03
|
|
Introduce test for checkout case-changing rename
|
|
f7fcb18f
|
2014-11-23T14:12:54
|
|
Plug leaks
Valgrind is now clean except for libssl and libgcrypt.
|
|
9f664347
|
2014-11-06T14:40:21
|
|
checkout_index: remove conflicts when checking out new files
|
|
b8add6c4
|
2014-08-03T15:44:13
|
|
Allow to propagate checkout callbacks to git HARD reset
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
6affd71f
|
2014-01-03T17:38:34
|
|
git_checkout_opts -> git_checkout_options
|
|
586be3b8
|
2014-02-03T15:05:55
|
|
Add reflog parameters to git_reset
|
|
b31ebfbc
|
2014-01-27T14:12:29
|
|
Add reflog params to git_branch_create
|
|
94f263f5
|
2014-01-25T08:04:49
|
|
Add reflog params to set-head calls
|
|
d541170c
|
2014-01-24T11:36:41
|
|
index: rename an entry's id to 'id'
This was not converted when we converted the rest, so do it now.
|
|
e8b81c69
|
2014-01-22T13:24:32
|
|
Preserve tree filemode in index during checkout
Don't try to determine whether the system supports file modes
when putting the tree data in the index during checkout. The tree's
mode is canonical and did not come from stat(2) in the first place.
|
|
0b28217b
|
2014-01-15T12:51:31
|
|
refs: remove the _with_log differentiation
Any well-behaved program should write a descriptive message to the
reflog whenever it updates a reference. Let's make this more prominent
by removing the version without the reflog parameters.
|
|
bf4a577c
|
2013-12-13T10:10:32
|
|
Overwrite ignored directories on checkout
|
|
81a2012d
|
2013-12-12T11:30:50
|
|
Overwrite ignored files on checkout
|
|
8046b26c
|
2013-12-10T16:16:36
|
|
Try a test that won't assert on Linux
|
|
cbd04896
|
2013-12-10T14:38:35
|
|
Fix checkout notify callback docs and tests
The checkout notify callback behavior on non-zero return values
was not being tested. This adds tests, fixes a bug with positive
values, and clarifies the documentation to make it clear that the
checkout can be canceled via this mechanism.
|
|
17820381
|
2013-11-14T14:05:52
|
|
Rename tests-clar to tests
|