D3252: tests: use `f --newer` instead of `stat -c` in test-fix.t
durin42 (Augie Fackler)
phabricator at mercurial-scm.org
Thu Apr 12 15:39:17 UTC 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG314f39e5fa86: tests: use `f --newer` instead of `stat -c` in test-fix.t (authored by durin42, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D3252?vs=8018&id=8071
REVISION DETAIL
https://phab.mercurial-scm.org/D3252
AFFECTED FILES
tests/test-fix.t
CHANGE DETAILS
diff --git a/tests/test-fix.t b/tests/test-fix.t
--- a/tests/test-fix.t
+++ b/tests/test-fix.t
@@ -492,11 +492,11 @@
$ printf "NO FIX NEEDED\n" > foo.whole
$ hg add
adding foo.whole
- $ OLD_MTIME=`stat -c %Y foo.whole`
- $ sleep 1 # mtime has a resolution of one second.
+ $ cp foo.whole foo.whole.orig
+ $ sleep 2 # mtime has a resolution of one or two seconds.
$ hg fix --working-dir
- $ NEW_MTIME=`stat -c %Y foo.whole`
- $ test $OLD_MTIME = $NEW_MTIME
+ $ f foo.whole --newer foo.whole.orig
+ foo.whole: older than foo.whole.orig
$ cd ..
To: durin42, #hg-reviewers, indygreg
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list