]> source.dussan.org Git - jgit.git/commit
Try to fix intermittent test failure related to file timestamps 61/29161/6
authorRobin Rosenberg <robin.rosenberg@dewire.com>
Sat, 28 Jun 2014 13:31:11 +0000 (15:31 +0200)
committerMatthias Sohn <matthias.sohn@sap.com>
Tue, 1 Jul 2014 13:29:11 +0000 (15:29 +0200)
commit0f14d3bf408d11549f861f22556c4740f9c13207
tree390a26846d2ec000af2b1f188e6c4640b40a739d
parent10aee9b1b70a857548adbd37592fb0c7ece024bb
Try to fix intermittent test failure related to file timestamps

Improve how tests do a "touch" operation on files. Instead of doing
"f.setLastModified(System.currentTimeMillis)" open a Outputstream on the
file and directly close it again. This makes this method rely only on
one clock - the clock of the filesystem.

Bug: 436917
Change-Id: I68ef3c2878f28b12daebf2ef6a9fa0a5d6e0964d
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/RepositoryTestCase.java