summaryrefslogtreecommitdiff
path: root/tests/resources
Commit message (Collapse)AuthorAgeFilesLines
* checkout: disallow bad paths on HFSEdward Thomson2014-12-1749-0/+37
| | | | | | | | HFS filesystems ignore some characters like U+200C. When these characters are included in a path, they will be ignored for the purposes of comparison with other paths. Thus, if you have a ".git" folder, a folder of ".git<U+200C>" will also match. Protect our ".git" folder by ensuring that ".git<U+200C>" and friends do not match it.
* checkout: disallow bad paths on win32Edward Thomson2014-12-1780-0/+64
| | | | | | | | | | | | | | | Disallow: 1. paths with trailing dot 2. paths with trailing space 3. paths with trailing colon 4. paths that are 8.3 short names of .git folders ("GIT~1") 5. paths that are reserved path names (COM1, LPT1, etc). 6. paths with reserved DOS characters (colons, asterisks, etc) These paths would (without \\?\ syntax) be elided to other paths - for example, ".git." would be written as ".git". As a result, writing these paths literally (using \\?\ syntax) makes them hard to operate with from the shell, Windows Explorer or other tools. Disallow these.
* revert tests: always use core.autocrlf=false in testsEdward Thomson2014-10-2712-4/+2
|
* git_rebase_commit: drop already-picked commitsEdward Thomson2014-10-2610-0/+5
| | | | | | Already cherry-picked commits should not be re-included. If all changes included in a commit exist in the upstream, then we should error with GIT_EAPPLIED.
* Introduce git_rebase to set up a rebase sessionEdward Thomson2014-10-26124-0/+167
| | | | | | Introduce `git_rebase` to set up a rebase session that can then be continued. Immediately, only merge-type rebase is supported.
* Introduce failing test for conflict filtering in indexEdward Thomson2014-10-133-0/+0
|
* Merge pull request #2473 from arthurschreiber/arthur/new-javascript-test-filesEdward Thomson2014-10-1014-351/+325
|\ | | | | New test files for the javascript diff driver.
| * Update the javascript diff driver's function pattern.Arthur Schreiber2014-10-091-3/+3
| |
| * New test files for the javascript diff driver.Arthur Schreiber2014-10-0914-351/+325
| |
* | Merge pull request #2592 from libgit2/cmn/describeCarlos Martín Nieto2014-10-0953-0/+54
|\ \ | |/ |/| Implement git-describe
| * tests: Add "describe" test repositorynulltoken2014-04-3053-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Built with the following script: #!/bin/sh test_tick () { sleep 10 } test_tick && echo one >file && git add file && git commit -m initial && one=$(git rev-parse HEAD) && git describe --always HEAD && test_tick && echo two >file && git add file && git commit -m second && two=$(git rev-parse HEAD) && test_tick && echo three >file && git add file && git commit -m third && test_tick && echo A >file && git add file && git commit -m A && test_tick && git tag -a -m A A && test_tick && echo c >file && git add file && git commit -m c && test_tick && git tag c && git reset --hard $two && test_tick && echo B >side && git add side && git commit -m B && test_tick && git tag -a -m B B && test_tick && git merge -m Merged c && merged=$(git rev-parse HEAD) && git reset --hard $two && test_tick && echo D >another && git add another && git commit -m D && test_tick && git tag -a -m D D && test_tick && git tag -a -m R R && test_tick && echo DD >another && git commit -a -m another && test_tick && git tag e && test_tick && echo DDD >another && git commit -a -m "yet another" && test_tick && git merge -m Merged $merged && test_tick && echo X >file && echo X >side && git add file side && git commit -m x
* | config: Add test cases that have trailing spaces before comment charsLinquize2014-10-041-0/+6
| |
* | Revert "test: Remove symlinks from the source tree"Vicent Marti2014-08-181-0/+1
| | | | | | | | This reverts commit 0dc54e149498bbd5de5e5ecc6006f9f5afb6588c.
* | test: Remove symlinks from the source treeVicent Marti2014-08-181-1/+0
|/ | | | We don't really use this at all, and it breaks packaging in Windows.
* Merge pull request #2261 from jacquesg/format-patchVicent Marti2014-04-1689-0/+72
|\ | | | | Support for format-patch
| * Added git_diff_stats test filesJacques Germishuys2014-04-1589-0/+72
| |
* | Added cherry pick testsJacques Germishuys2014-04-1490-0/+96
|/
* Merge pull request #2178 from libgit2/rb/fix-short-idEdward Thomson2014-03-311-0/+0
|\ | | | | Fix git_odb_short_id and git_odb_exists_prefix bugs
| * Add failing test for git_object_short_idJiri Pospisil2014-03-101-0/+0
| |
* | Add `git_merge_status` to provide info about an upcoming mergeEdward Thomson2014-03-201-0/+1
|/
* Add PHP tests and fix bug in PHP builtin driverRussell Belfer2014-01-2713-3/+204
|
* Update Javascript userdiff driver and testsRussell Belfer2014-01-2723-5/+410
| | | | | | | | | Writing a sample Javascript driver pointed out some extra whitespace handling that needed to be done in the diff driver. This adds some tests with some sample javascript code that I pulled off of GitHub just to see what would happen. Also, to clean up the userdiff test data, I did a "git gc" and packed up the test objects.
* Move userdiff tests to be data drivenRussell Belfer2014-01-2421-0/+189
| | | | | | This moves the expected and actual test data along with the source data for the userdiff tests into the tests/resources/userdiff test repo and updates the test to use that.
* Preserve tree filemode in index during checkoutEdward Thomson2014-01-223-0/+0
| | | | | | 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.
* Merge submodulesEdward Thomson2014-01-2045-0/+44
|
* Don't try to merge binary filesEdward Thomson2014-01-209-0/+3
|
* merge_file should use more aggressive levelsEdward Thomson2014-01-2023-1/+9
| | | | | | | | | | | The default merge_file level was XDL_MERGE_MINIMAL, which will produce conflicts where there should not be in the case where both sides were changed identically. Change the defaults to be more aggressive (XDL_MERGE_ZEALOUS) which will more aggressively compress non-conflicts. This matches git.git's defaults. Increase testing around reverting a previously reverted commit to illustrate this problem.
* Handle git_buf's from users more liberallyEdward Thomson2014-01-084-1/+1
|
* Introduce git_revert to revert a single commitEdward Thomson2013-12-0245-0/+91
|
* tree-cache: Don't segfault upon corruptionnulltoken2013-11-191-0/+0
|
* Rename tests-clar to testsBen Straub2013-11-141794-0/+2854
|
* Backport more test dataVicent Martí2012-05-0266-57/+0
|
* Move test resourcesVicent Martí2012-05-0298-130/+0
|
* Merge branch 'new-error-handling' into developmentVicent Martí2012-05-02111-0/+144
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .travis.yml include/git2/diff.h src/config_file.c src/diff.c src/diff_output.c src/mwindow.c src/path.c tests-clar/clar_helpers.c tests-clar/object/tree/frompath.c tests/t00-core.c tests/t03-objwrite.c tests/t08-tag.c tests/t10-refs.c tests/t12-repo.c tests/t18-status.c tests/test_helpers.c tests/test_main.c
| * Include the new config test fileCarlos Martín Nieto2012-04-251-0/+2
| |
| * config: parse quoted valuesCarlos Martín Nieto2012-04-161-0/+7
| | | | | | | | | | Variable values may be quoted to include newlines, literal quotes and other characters. Add support for these and test it.
| * tag: Add git_tag_peel() which recursively peel a tag until a non tag ↵nulltoken2012-04-102-0/+1
| | | | | | | | git_object is met
| * Fix handling of submodules in treesRussell Belfer2012-03-266-0/+6
| |
| * Fix error in tree iterator when popping up treesRussell Belfer2012-03-2513-1/+9
| | | | | | | | | | | | | | | | | | | | There was an error in the tree iterator where it would delete two tree levels instead of just one when popping up a tree level. Unfortunately the test data for the tree iterator did not have any deep trees with subtrees in the middle of the tree items, so this problem went unnoticed. This contains the 1-line fix plus new test data and tests that reveal the issue.
| * Adding new tests for new status commandRussell Belfer2012-03-2295-0/+124
| | | | | | | | | | | | | | | | This is a work in progress. This adds two new sets of tests, the issue_592 tests from @nulltoken's pull request #601 and some new tests for submodules. The submodule tests still have issues where the status is not reported correctly. That needs to be fixed before merge.
* | Merge pull request #606 from benstraub/t04_commit_to_clarVicent Martí2012-04-0253-0/+43
|\ \ | | | | | | Ported t04_commit.c to Clar.
| * | Ported t04_commit.c to Clar.Ben Straub2012-03-2053-0/+43
| |/ | | | | | | | | | | | | | | | | | | Created a copy of tests/resources/testrepo.git that is compatible with the Clar sandboxing helpers. Restructured commit test suites to use Clar sandbox helpers. Now using typed data arrays rather than lots of macros to define test cases.
* | Moved testing resources to clar, and removed old tests directory.Ben Straub2012-03-31267-471/+0
| | | | | | | | Removed the BUILD_CLAR CMake flag, and updated the readme.
* | t08_tag.c ported.Ben Straub2012-03-3053-0/+43
|/ | | | Also cleaned up some names for things that used to be macros.
* Add tests and fix bugs for diff whitespace optionsRussell Belfer2012-03-028-4/+15
| | | | | | Once I added tests for the whitespace handling options of diff, I realized that there were some bugs. This fixes those and adds the new tests into the test suite.
* Clean up diff implementation for reviewRussell Belfer2012-03-021-0/+0
| | | | | | | This fixes several bugs, updates tests and docs, eliminates the FILE* assumption in favor of printing callbacks for the diff patch formatter helpers, and adds a "diff" example function that can perform a diff from the command line.
* Initial implementation of git_diff_blobRussell Belfer2012-03-0215-3/+43
| | | | | | | | This gets the basic plumbing in place for git_diff_blob. There is a known issue where additional parameters like the number of lines of context to display on the diff are not working correctly (which leads one of the new unit tests to fail).
* Add test for possible attr bugRussell Belfer2012-03-022-0/+7
| | | | | This is a test that should replicate an issue that Peff is setting with git attributes. But the test doesn't fail.
* Implement setting multivarsCarlos Martín Nieto2012-02-171-2/+2
|
* tests: add multivar read testCarlos Martín Nieto2012-02-171-0/+3
|