mirror of
https://github.com/git/git.git
synced 2026-03-17 04:00:11 +01:00
Merge branch 'js/test-windows' into next
* js/test-windows: t/README: hint about using $(pwd) rather than $PWD in tests Fix expected values of setup tests on Windows
This commit is contained in:
6
t/README
6
t/README
@@ -283,6 +283,12 @@ Do:
|
||||
Tests that are likely to smoke out future regressions are better
|
||||
than tests that just inflate the coverage metrics.
|
||||
|
||||
- When a test checks for an absolute path that a git command generated,
|
||||
construct the expected value using $(pwd) rather than $PWD,
|
||||
$TEST_DIRECTORY, or $TRASH_DIRECTORY. It makes a difference on
|
||||
Windows, where the shell (MSYS bash) mangles absolute path names.
|
||||
For details, see the commit message of 4114156ae9.
|
||||
|
||||
Don't:
|
||||
|
||||
- exit() within a <script> part.
|
||||
|
||||
@@ -343,7 +343,7 @@ test_expect_success 'make_relative_path handles double slashes in GIT_DIR' '
|
||||
test_expect_success 'relative $GIT_WORK_TREE and git subprocesses' '
|
||||
GIT_DIR=repo.git GIT_WORK_TREE=repo.git/work \
|
||||
test-subprocess --setup-work-tree rev-parse --show-toplevel >actual &&
|
||||
echo "$TRASH_DIRECTORY/repo.git/work" >expected &&
|
||||
echo "$(pwd)/repo.git/work" >expected &&
|
||||
test_cmp expected actual
|
||||
'
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user