[PATCH] t0020: make sure the test file is lf to start with
- From
vfr@lyx.org <vfr@lyx.org>
- Date
- Jun 10, 2012, 10:32 UTC
- Message-ID
- <1339324352-7376-1-git-send-email-vfr@lyx.org>
From: Vincent van Ravesteijn <vfr@lyx.org>
On Windows, the perl interpreter used by q_to_nul also converts the eol-style to crlf. Because the eol-style is now wrong from the beginning, the later tests '.gitattributes says two is binary' and 'checkout with existing .gitattributes' fail. This patch makes sure that the eol-style is lf when the test file is setup and makes the tests to pass also on Windows.
Signed-off-by: Vincent van Ravesteijn <vfr@lyx.org>
--- I'm not sure everyone will like this solution to fix a problem that is only present on Windows. I'd be happy to discuss a different solution.
t/t0020-crlf.sh | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/t/t0020-crlf.sh b/t/t0020-crlf.sh index 1a8f44c..4c41b6e 100755 --- a/t/t0020-crlf.sh +++ b/t/t0020-crlf.sh @@ -15,7 +15,7 @@ test_expect_success setup ' for w in Hello world how are you; do echo $w; done >one && mkdir dir && for w in I am very very fine thank you; do echo $w; done >dir/two && - for w in Oh here is NULQin text here; do echo $w; done | q_to_nul >three && + for w in Oh here is NULQin text here; do echo $w; done | q_to_nul | remove_cr >three && git add . && git commit -m initial &&
-- 1.7.9.msysgit.0