Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2003-12-04 21:56:41 +0000
committerMichael Valenta2003-12-04 21:56:41 +0000
commit52aa0fc9de77625d07121ec22dc06c3d274dc6c4 (patch)
tree8735a248a4ab8f1ddb0c9418613b098194913431 /tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team
parent85ca87d62f5be9a6deaaae62eccfabf9c81aba30 (diff)
downloadeclipse.platform.team-52aa0fc9de77625d07121ec22dc06c3d274dc6c4.tar.gz
eclipse.platform.team-52aa0fc9de77625d07121ec22dc06c3d274dc6c4.tar.xz
eclipse.platform.team-52aa0fc9de77625d07121ec22dc06c3d274dc6c4.zip
46480: Assertion failure when synchronize view updates using 1111 integration build
Diffstat (limited to 'tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team')
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/subscriber/CVSWorkspaceSubscriberTest.java41
1 files changed, 39 insertions, 2 deletions
diff --git a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/subscriber/CVSWorkspaceSubscriberTest.java b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/subscriber/CVSWorkspaceSubscriberTest.java
index 72985d296..ced37be9a 100644
--- a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/subscriber/CVSWorkspaceSubscriberTest.java
+++ b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/subscriber/CVSWorkspaceSubscriberTest.java
@@ -1270,9 +1270,46 @@ public class CVSWorkspaceSubscriberTest extends CVSSyncSubscriberTest {
assertSyncEquals("testNestedMarkAsMerged sync check", project,
new String[] { "folder2/", "folder2/file.txt", "folder2/file2.txt"},
true, new int[] {
- SyncInfo.IN_SYNC,
- SyncInfo.OUTGOING | SyncInfo.CHANGE,
+ SyncInfo.IN_SYNC,
+ SyncInfo.OUTGOING | SyncInfo.CHANGE,
+ SyncInfo.CONFLICTING | SyncInfo.ADDITION
+ });
+ }
+
+ public void testMarkAsMergedOnBinaryFile() throws TeamException, CoreException, InvocationTargetException, InterruptedException {
+ // Create a project and checkout a copy
+ IProject project = createProject(new String[] { "file1.txt"});
+ IProject copy = checkoutCopy(project, "-copy");
+ // Add the same binary file to both projects to create a conflicting addition
+ buildResources(project, new String[] {"binary.gif"}, false);
+ addResources(copy, new String[] {"binary.gif"}, true);
+ assertIsBinary(copy.getFile("binary.gif"));
+ assertSyncEquals("testMarkAsMergedOnBinaryFile sync check", project,
+ new String[] {"binary.gif"},
+ true, new int[] {
+ SyncInfo.CONFLICTING | SyncInfo.ADDITION
+ });
+ markAsMerged(getSubscriber(), project, new String[] {"binary.gif"});
+ assertSyncEquals("testMarkAsMergedOnBinaryFile sync check", project,
+ new String[] {"binary.gif"},
+ true, new int[] {
+ SyncInfo.OUTGOING | SyncInfo.CHANGE
+ });
+ assertIsBinary(project.getFile("binary.gif"));
+ // Unmanage the file and do it again
+ // This tests the case were the contents are already cached locally
+ CVSWorkspaceRoot.getCVSFileFor(project.getFile("binary.gif")).unmanage(DEFAULT_MONITOR);
+ assertSyncEquals("testMarkAsMergedOnBinaryFile sync check", project,
+ new String[] {"binary.gif"},
+ true, new int[] {
SyncInfo.CONFLICTING | SyncInfo.ADDITION
});
+ markAsMerged(getSubscriber(), project, new String[] {"binary.gif"});
+ assertSyncEquals("testMarkAsMergedOnBinaryFile sync check", project,
+ new String[] {"binary.gif"},
+ true, new int[] {
+ SyncInfo.OUTGOING | SyncInfo.CHANGE
+ });
+ assertIsBinary(project.getFile("binary.gif"));
}
}

Back to the top