@matheusbsbs / matheus-bagliano / commits / 95b104c830
Fork 0

t/README: hint about using $(pwd) rather than $PWD in tests

This adds just a "do it this way" instruction without a lot of explanation, because the details are too complex to be explained at this point. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Johannes Sixt committed Jan 11, 2011 at 08:44 UTC 95b104c830caa74a5702bcabc3bbb920b0eba07d
1 file changed +6
t/README
+6
@@ -283,6 +283,12 @@ Do:
283 Tests that are likely to smoke out future regressions are better
284 than tests that just inflate the coverage metrics.
285
286 + - When a test checks for an absolute path that a git command generated,
287 + construct the expected value using $(pwd) rather than $PWD,
288 + $TEST_DIRECTORY, or $TRASH_DIRECTORY. It makes a difference on
289 + Windows, where the shell (MSYS bash) mangles absolute path names.
290 + For details, see the commit message of 4114156ae9.
291 +
292 Don't:
293
294 - exit() within a <script> part.