use of com.intellij.history.core.tree.Entry in project intellij-community by JetBrains.
the class RevisionsAndDiffsTest method testIncludingCurrentVersionIntoRevisionsAfterPurge.
public void testIncludingCurrentVersionIntoRevisionsAfterPurge() throws Exception {
Clock.setTime(10);
VirtualFile f = createFile("file.txt", "content");
loadContent(f);
getVcs().getChangeListInTests().purgeObsolete(0);
List<Revision> rr = getRevisionsFor(f);
assertEquals(1, rr.size());
Revision r = rr.get(0);
assertNull(r.getLabel());
assertNull(r.getChangeSetName());
assertEquals(f.getTimeStamp(), r.getTimestamp());
Entry e = r.findEntry();
assertEquals("file.txt", e.getName());
assertContent("content", e);
}
use of com.intellij.history.core.tree.Entry in project intellij-community by JetBrains.
the class RevisionsAndDiffsTest method testCurrentRevisionForDirectoryAfterPurge.
public void testCurrentRevisionForDirectoryAfterPurge() throws Exception {
Clock.setTime(10);
VirtualFile f = createDirectory("dir");
getVcs().getChangeListInTests().purgeObsolete(0);
List<Revision> rr = getRevisionsFor(f);
assertEquals(1, rr.size());
Revision r = rr.get(0);
assertNull(r.getLabel());
assertNull(r.getChangeSetName());
// directory has no timestamp
assertEquals(-1, r.getTimestamp());
Entry e = r.findEntry();
assertEquals("dir", e.getName());
}
Aggregations