Mercurial > hg4j
diff test/org/tmatesoft/hg/test/TestStatus.java @ 429:cd658b24a620
FIXMEs: javadoc, proper use of constants
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Thu, 29 Mar 2012 18:29:03 +0200 |
parents | 31a89587eb04 |
children | 6865eb742883 |
line wrap: on
line diff
--- a/test/org/tmatesoft/hg/test/TestStatus.java Thu Mar 29 18:05:05 2012 +0200 +++ b/test/org/tmatesoft/hg/test/TestStatus.java Thu Mar 29 18:29:03 2012 +0200 @@ -21,6 +21,7 @@ import static org.junit.Assert.assertTrue; import static org.tmatesoft.hg.core.HgStatus.Kind.*; import static org.tmatesoft.hg.repo.HgRepository.TIP; +import static org.tmatesoft.hg.repo.HgRepository.WORKING_COPY; import java.io.File; import java.util.ArrayList; @@ -382,7 +383,7 @@ final Path file3 = Path.create("dir/file3"); HgWorkingCopyStatusCollector sc = HgWorkingCopyStatusCollector.create(repo, file2, file3); HgStatusCollector.Record r = new HgStatusCollector.Record(); - sc.walk(TIP, r); + sc.walk(WORKING_COPY, r); assertTrue(r.getAdded().isEmpty()); assertTrue(r.getRemoved().isEmpty()); assertTrue(r.getUnknown().isEmpty()); @@ -397,7 +398,7 @@ final Path readme = Path.create("readme"); final Path dir = Path.create("dir/"); sc = HgWorkingCopyStatusCollector.create(repo, readme, dir); - sc.walk(TIP, r = new HgStatusCollector.Record()); + sc.walk(WORKING_COPY, r = new HgStatusCollector.Record()); assertTrue(r.getAdded().isEmpty()); assertTrue(r.getRemoved().size() == 2); for (Path p : r.getRemoved()) { @@ -421,13 +422,13 @@ HgWorkingCopyStatusCollector sc = HgWorkingCopyStatusCollector.create(repo, file3, file5); HgStatusCollector.Record r; - sc.walk(TIP, r = new HgStatusCollector.Record()); + sc.walk(WORKING_COPY, r = new HgStatusCollector.Record()); assertTrue(r.getRemoved().contains(file5)); assertTrue(r.getIgnored().contains(file3)); // // query for the same file, but with sc = HgWorkingCopyStatusCollector.create(repo, new PathGlobMatcher(file3.toString(), file5.toString())); - sc.walk(TIP, r = new HgStatusCollector.Record()); + sc.walk(WORKING_COPY, r = new HgStatusCollector.Record()); assertTrue(r.getRemoved().contains(file5)); assertTrue(r.getIgnored().contains(file3)); }