- 03 Mar, 2015 1 commit
-
-
This changes the get_entry() method to return a refcounted version of the config entry, which you have to free when you're done. This allows us to avoid freeing the memory in which the entry is stored on a refresh, which may happen at any time for a live config. For this reason, get_string() has been forbidden on live configs and a new function get_string_buf() has been added, which stores the string in a git_buf which the user then owns. The functions which parse the string value takea advantage of the borrowing to parse safely and then release the entry.
Carlos Martín Nieto committed
-
- 19 Feb, 2015 1 commit
-
-
Introduce GITTEST_INVASIVE_FS_STRUCTURE for things that are invasive to your filesystem structure (like creating folders at your filesystem root) and GITTEST_INVASIVE_FS_SIZE for things that write lots of data.
Edward Thomson committed
-
- 05 Feb, 2015 1 commit
-
-
Test to ensure that we can create a repository at the filesystem root. Introduces a new test environment variable, `GITTEST_INVASIVE_FILESYSTEM` for tests that do terrible things like escaping the clar sandbox and writing to the root directory. It is expected that the CI builds will enable this but that normal people would not want this.
Edward Thomson committed
-
- 08 Jan, 2015 1 commit
-
-
Remove the hook symlink from the test resources, so that we can have a source tree that is easy to zip up and copy around on systems that don't support symlinks. Create it dynamically at test execution instead.
Edward Thomson committed
-
- 08 Nov, 2014 1 commit
-
-
This brings it in line with the rest of the lookup functions.
Carlos Martín Nieto committed
-
- 17 Sep, 2014 1 commit
-
-
Carlos Martín Nieto committed
-
- 03 Sep, 2014 1 commit
-
-
Teach git_repository_init_ext to use relative paths for the gitlink to the work directory. This is used when creating a sub repository where the sub repository resides in the parent repository's .git directory.
Jameson Miller committed
-
- 14 Nov, 2013 1 commit
-
-
Ben Straub committed
-
- 01 Nov, 2013 1 commit
-
-
Vicent Marti committed
-
- 03 Oct, 2013 3 commits
-
-
This cleans up more of the test suite to check actual filesystem behavior instead of relying on Windows vs. Mac vs. Linux to test.
Russell Belfer committed -
The repo init code was assuming Windows == no filemode, and Mac or Windows == no case sensitivity. Those assumptions are not consistently true depending on the mounted file system. This is a first step to removing those assumptions. It focuses on the repo init code and the tests of that code. There are still many other tests that are broken when those assumptions don't hold true, but this clears up one area of the code. Also, this moves the core.precomposeunicode logic to be closer to the current logic in core Git where it will be set to true on any filesystem where composed unicode is decomposed when read back.
Russell Belfer committed -
This adds initialization of core.precomposeunicode to repo init on Mac. This is necessary because when a Mac accesses a repo on a VFAT or SAMBA file system, it will return directory entries in decomposed unicode even if the filesystem entry is precomposed. This also removes caching of a number of repo properties from the repo init pipeline because these are properties of the specific filesystem on which the repo is created, not of the system as a whole.
Russell Belfer committed
-
- 24 Sep, 2013 1 commit
-
-
Russell Belfer committed
-
- 17 Sep, 2013 1 commit
-
-
There were a lot of places in the test code base that were creating a commit from the index on the current branch. This just adds a helper to handle that case pretty easily. There was only one test where this change ended up tweaking the test data, so pretty easy and mostly just a cleanup.
Russell Belfer committed
-
- 05 Sep, 2013 3 commits
-
-
Russell Belfer committed
-
The GIT_MODE_TYPE macro was looking at all bits above the permissions, but it should really just look at the top bits so that it will give the right results for a setgid or setuid entry. Since we're now using these macros in the tests, this was causing a test failure on platforms that don't support setgid.
Russell Belfer committed -
This fixes an issue checking file modes in the tests that initialize a repo from a template directory when a symlink is used in the template. Also, this updates some other places where we are examining file modes to use the new macros.
Russell Belfer committed
-
- 04 Sep, 2013 3 commits
-
-
Some windows tests were failing
Russell Belfer committed -
Russell Belfer committed
-
It seems that libgit2 is correctly applying the umask when initializing a repository from a template and when creating new directories during checkout, but the test suite is not accounting for possible variations due to the umask. This updates that so that the test suite will work regardless of the umask.
Russell Belfer committed
-
- 16 Aug, 2013 2 commits
-
-
Russell Belfer committed
-
Russell Belfer committed
-
- 22 Mar, 2013 1 commit
-
-
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.
Russell Belfer committed
-
- 27 Feb, 2013 1 commit
-
-
When creating files, instead of actually using GIT_FILEMODE_BLOB and the other various constants that happen to correspond to mode values, apparently I should be just using 0666 and 0777, and relying on the umask to clear bits and make the value sane. This fixes the rules for copying a template directory and fixes the checks to match that new behavior. (Further changes to the checkout logic to follow separately.)
Russell Belfer committed
-
- 26 Feb, 2013 2 commits
-
-
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.
Russell Belfer committed -
When PR #1359 removed the hooks from the test resources/template directory, it made me realize that the tests for git_repository_init_ext using templates must be pretty shabby because we could not have been testing if the hooks were getting created correctly. So, this started with me recreating a couple of hooks, including a sample and symlink, and adding tests that they got created correctly in the various circumstances, including with the SHARED modes, etc. Unfortunately this uncovered some issues with how directories and symlinks were copied and chmod'ed. Also, there was a FIXME in the code related to the chmod behavior as well. Going back over the directory creation logic for setting up a repository, I found it was a little difficult to read and could result in creating and/or chmod'ing directories that the user almost certainly didn't intend. So that let to this work which makes repo initialization much more careful (and hopefully easier to follow). It required a couple of extensions / changes to core fileops utilities, but I also think those are for the better, at least for git_futils_cp_r in terms of being careful about what actions it takes.
Russell Belfer committed
-
- 07 Feb, 2013 1 commit
-
-
Scott J. Goldman committed
-
- 13 Jan, 2013 1 commit
-
-
been properly copied. This is a minimal effort to test whether the template really has been used when creating an repo with external templates.
Sebastian Bauer committed
-
- 12 Jan, 2013 1 commit
-
-
Otherwise the template functionallity is not tested (as a TODO we also shall test that the specified template really got copied).
Sebastian Bauer committed
-
- 30 Nov, 2012 1 commit
-
-
Ben Straub committed
-
- 27 Nov, 2012 1 commit
-
-
Ben Straub committed
-
- 23 Nov, 2012 1 commit
-
-
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
Sascha Cunz committed
-
- 29 Aug, 2012 1 commit
-
-
nulltoken committed
-
- 24 Aug, 2012 1 commit
-
-
Russell Belfer committed
-
- 22 Aug, 2012 1 commit
-
-
This extends git_repository_init_ext further with support for initializing the repository from an external template directory and with support for the "create shared" type flags that make a set GID repository directory. This also adds tests for much of the new functionality to the existing `repo/init.c` test suite. Also, this adds a bunch of new utility functions including a very general purpose `git_futils_mkdir` (with the ability to make paths and to chmod the paths post-creation) and a file tree copying function `git_futils_cp_r`. Also, this includes some new path functions that were useful to keep the code simple.
Russell Belfer committed
-
- 03 Jul, 2012 1 commit
-
-
Carlos Martín Nieto committed
-
- 22 Jun, 2012 2 commits
- 21 Jun, 2012 1 commit
-
-
The second call to assert_config_entry_on_init_bytype is cleaned up by the main cleanup function, but that overwrites the first _repo. Make sure that one doesn't leak.
Carlos Martín Nieto committed
-
- 12 Jun, 2012 1 commit
-
-
nulltoken committed
-