Mercurial > hg4j
comparison test/org/tmatesoft/hg/test/TestAddRemove.java @ 536:2813a26b8999
Tests: refactor various utility methods to a single location
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Tue, 05 Feb 2013 16:36:58 +0100 |
parents | 95bdcf75e71e |
children | 6ca3d0c5b4bc |
comparison
equal
deleted
inserted
replaced
535:d9c07e1432c4 | 536:2813a26b8999 |
---|---|
45 public TestAddRemove() { | 45 public TestAddRemove() { |
46 } | 46 } |
47 | 47 |
48 @Test | 48 @Test |
49 public void testScheduleAddition() throws Exception { | 49 public void testScheduleAddition() throws Exception { |
50 File testRepoLoc = TestRevert.cloneRepoToTempLocation("log-1", "test-addremove-1", false); | 50 File testRepoLoc = RepoUtils.cloneRepoToTempLocation("log-1", "test-addremove-1", false); |
51 repo = new HgLookup().detect(testRepoLoc); | 51 repo = new HgLookup().detect(testRepoLoc); |
52 | 52 |
53 StatusOutputParser statusParser = new StatusOutputParser(); | 53 StatusOutputParser statusParser = new StatusOutputParser(); |
54 eh = new ExecHelper(statusParser, testRepoLoc); | 54 eh = new ExecHelper(statusParser, testRepoLoc); |
55 eh.run("hg", "status", "-A"); | 55 eh.run("hg", "status", "-A"); |
70 assertEquals(2, statusParser.getAdded().size()); | 70 assertEquals(2, statusParser.getAdded().size()); |
71 } | 71 } |
72 | 72 |
73 @Test | 73 @Test |
74 public void testScheduleRemoval() throws Exception { | 74 public void testScheduleRemoval() throws Exception { |
75 File testRepoLoc = TestRevert.cloneRepoToTempLocation("log-1", "test-addremove-2", false); | 75 File testRepoLoc = RepoUtils.cloneRepoToTempLocation("log-1", "test-addremove-2", false); |
76 repo = new HgLookup().detect(testRepoLoc); | 76 repo = new HgLookup().detect(testRepoLoc); |
77 | 77 |
78 StatusOutputParser statusParser = new StatusOutputParser(); | 78 StatusOutputParser statusParser = new StatusOutputParser(); |
79 eh = new ExecHelper(statusParser, testRepoLoc); | 79 eh = new ExecHelper(statusParser, testRepoLoc); |
80 eh.run("hg", "status", "-A"); | 80 eh.run("hg", "status", "-A"); |