use of org.jetbrains.idea.svn.info.Info in project intellij-community by JetBrains.
the class SvnChangeProviderContext method addModifiedNotSavedChange.
public void addModifiedNotSavedChange(@NotNull VirtualFile file) throws SVNException {
final FilePath filePath = VcsUtil.getFilePath(file);
final Info svnInfo = myVcs.getInfo(file);
if (svnInfo != null) {
final Status svnStatus = new Status();
svnStatus.setRevision(svnInfo.getRevision());
svnStatus.setKind(NodeKind.from(filePath.isDirectory()));
processChangeInList(SvnContentRevision.createBaseRevision(myVcs, filePath, svnInfo.getRevision()), CurrentContentRevision.create(filePath), FileStatus.MODIFIED, svnStatus);
}
}
use of org.jetbrains.idea.svn.info.Info in project intellij-community by JetBrains.
the class SvnMergeInfoTest method testMixedWorkingRevisions.
@Test
public void testMixedWorkingRevisions() throws Exception {
createOneFolderStructure();
// rev 3
editAndCommit(trunk, f1);
// rev 4: record non inheritable merge
setMergeInfo(myBranchVcsRoot, "/trunk:3");
commitFile(myBranchVcsRoot);
// ! no update!
assertMergeInfo(myBranchVcsRoot, "/trunk:3");
final Info f1info = myVcs.getInfo(new File(myBranchVcsRoot, "folder/f1.txt"));
assert f1info.getRevision().getNumber() == 2;
final List<SvnChangeList> changeListList = getTrunkChangeLists();
final SvnChangeList changeList = changeListList.get(0);
assertMergeResult(changeList, SvnMergeInfoCache.MergeCheckResult.NOT_MERGED);
// and after update
updateFile(myBranchVcsRoot);
myMergeChecker.clear();
assertMergeResult(changeList, SvnMergeInfoCache.MergeCheckResult.MERGED);
}
Aggregations