@Test public void testCopyUnversionedFile() throws Exception { VirtualFile file = makeFile(new File(myWorkingCopyDir.getPath(), "a.txt")); copyFileInCommand(file, "b.txt"); verify( runHgOnProjectRepo("status"), HgTestOutputParser.unknown("a.txt"), HgTestOutputParser.unknown("b.txt")); }
@Test public void testCopyCopiedFile() throws Exception { VirtualFile file = createFileInCommand("a.txt", "new file content"); runHgOnProjectRepo("commit", "-m", "added file"); copyFileInCommand(file, "b.txt"); copyFileInCommand(file, "c.txt"); verify( runHgOnProjectRepo("status"), HgTestOutputParser.added("b.txt"), HgTestOutputParser.added("c.txt")); }
@Test public void testCopyDirWithFiles() throws Exception { VirtualFile parent = createDirInCommand(myWorkingCopyDir, "com"); createFileInCommand(parent, "a.txt", "new file content"); runHgOnProjectRepo("commit", "-m", "added file"); copyFileInCommand(parent, "org"); verify(runHgOnProjectRepo("status"), HgTestOutputParser.added("org", "a.txt")); }