Skip to main content
aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/org.eclipse.compare.tests/.classpath2
-rw-r--r--tests/org.eclipse.compare.tests/build.properties6
-rw-r--r--tests/org.eclipse.compare.tests/plugin.xml6
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/AllTests.java (renamed from tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/AllTests.java)7
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/CompareTestPlugin.java31
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/DocLineComparatorTest.java (renamed from tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/DocLineComparatorTest.java)1
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/FilterTest.java (renamed from tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/FilterTest.java)32
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/StreamMergerTest.java (renamed from tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/StreamMergerTest.java)16
-rw-r--r--tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/UITest.java24
9 files changed, 95 insertions, 30 deletions
diff --git a/tests/org.eclipse.compare.tests/.classpath b/tests/org.eclipse.compare.tests/.classpath
index 0c6403796..065ac06e1 100644
--- a/tests/org.eclipse.compare.tests/.classpath
+++ b/tests/org.eclipse.compare.tests/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="src" path="JUnit Tests"/>
+ <classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="output" path="bin"/>
diff --git a/tests/org.eclipse.compare.tests/build.properties b/tests/org.eclipse.compare.tests/build.properties
index 36c12d3a8..91d761ead 100644
--- a/tests/org.eclipse.compare.tests/build.properties
+++ b/tests/org.eclipse.compare.tests/build.properties
@@ -9,7 +9,11 @@
# IBM Corporation - initial API and implementation
###############################################################################
bin.includes= plugin.xml,\
+ plugin.properties,\
test.xml,\
about.html,\
*.jar
-source.comparetests.jar= JUnit Tests/
+
+src.includes = about.html
+
+source.comparetests.jar= src/
diff --git a/tests/org.eclipse.compare.tests/plugin.xml b/tests/org.eclipse.compare.tests/plugin.xml
index 007ce483b..1e4dce75c 100644
--- a/tests/org.eclipse.compare.tests/plugin.xml
+++ b/tests/org.eclipse.compare.tests/plugin.xml
@@ -4,14 +4,15 @@
id="org.eclipse.compare.tests"
name="%pluginName"
version="3.1.0"
- provider-name="%providerName">
+ provider-name="%providerName"
+ class="org.eclipse.compare.tests.CompareTestPlugin">
<runtime>
<library name="comparetests.jar">
<export name="*"/>
- <packages prefixes="org.eclipse.compare.tests"/>
</library>
</runtime>
+
<requires>
<import plugin="org.junit"/>
<import plugin="org.eclipse.compare"/>
@@ -21,5 +22,4 @@
<import plugin="org.eclipse.core.runtime"/>
</requires>
-
</plugin>
diff --git a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/AllTests.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/AllTests.java
index 02c5a4f72..8fae9d7ee 100644
--- a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/AllTests.java
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/AllTests.java
@@ -22,9 +22,10 @@ public class AllTests {
public static Test suite() {
TestSuite suite= new TestSuite("Test for org.eclipse.compare.tests"); //$NON-NLS-1$
//$JUnit-BEGIN$
- suite.addTestSuite(StreamMergerTest.class);
- suite.addTestSuite(DocLineComparatorTest.class);
- suite.addTestSuite(FilterTest.class);
+ suite.addTestSuite(UITest.class);
+ //suite.addTestSuite(StreamMergerTest.class);
+ //suite.addTestSuite(DocLineComparatorTest.class);
+ //suite.addTestSuite(FilterTest.class);
//$JUnit-END$
return suite;
}
diff --git a/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/CompareTestPlugin.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/CompareTestPlugin.java
new file mode 100644
index 000000000..e1d92a4c6
--- /dev/null
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/CompareTestPlugin.java
@@ -0,0 +1,31 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2004 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Common Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/cpl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.compare.tests;
+
+import org.eclipse.core.runtime.Plugin;
+
+/**
+ * The main plug-in class to be used in the desktop.
+ *
+ * @since 3.1
+ */
+public class CompareTestPlugin extends Plugin {
+
+ private static CompareTestPlugin fgPlugin;
+
+ public CompareTestPlugin() {
+ fgPlugin= this;
+ }
+
+ public static CompareTestPlugin getDefault() {
+ return fgPlugin;
+ }
+}
diff --git a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/DocLineComparatorTest.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/DocLineComparatorTest.java
index 2e3cc622e..2652df71c 100644
--- a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/DocLineComparatorTest.java
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/DocLineComparatorTest.java
@@ -25,6 +25,7 @@ public class DocLineComparatorTest extends TestCase {
}
protected void setUp() throws Exception {
+ // empty
}
protected void tearDown() throws Exception {
diff --git a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/FilterTest.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/FilterTest.java
index 0c650235c..20992cf40 100644
--- a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/FilterTest.java
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/FilterTest.java
@@ -25,34 +25,34 @@ public class FilterTest extends TestCase {
public void testFilterFile() {
CompareFilter f= new CompareFilter();
- f.setFilters("*.class");
- Assert.assertTrue("file foo.class should be filtered", f.filter("foo.class", false, false));
- Assert.assertFalse("file foo.java shouldn't be filtered", f.filter("foo.java", false, false));
+ f.setFilters("*.class"); //$NON-NLS-1$
+ Assert.assertTrue("file foo.class should be filtered", f.filter("foo.class", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file foo.java shouldn't be filtered", f.filter("foo.java", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
}
public void testFilterDotFile() {
CompareFilter f= new CompareFilter();
- f.setFilters(".cvsignore");
- Assert.assertTrue("file .cvsignore should be filtered", f.filter(".cvsignore", false, false));
- Assert.assertFalse("file foo.cvsignore shouldn't be filtered", f.filter("foo.cvsignore", false, false));
+ f.setFilters(".cvsignore"); //$NON-NLS-1$
+ Assert.assertTrue("file .cvsignore should be filtered", f.filter(".cvsignore", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file foo.cvsignore shouldn't be filtered", f.filter("foo.cvsignore", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
}
public void testFilterFolder() {
CompareFilter f= new CompareFilter();
- f.setFilters("bin/");
- Assert.assertTrue("folder bin should be filtered", f.filter("bin", true, false));
- Assert.assertFalse("file bin shouldn't be filtered", f.filter("bin", false, false));
+ f.setFilters("bin/"); //$NON-NLS-1$
+ Assert.assertTrue("folder bin should be filtered", f.filter("bin", true, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file bin shouldn't be filtered", f.filter("bin", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
}
public void testMultiFilter() {
CompareFilter f= new CompareFilter();
- f.setFilters("*.class, .cvsignore, bin/");
- Assert.assertTrue("file foo.class should be filtered", f.filter("foo.class", false, false));
- Assert.assertFalse("file foo.java shouldn't be filtered", f.filter("foo.java", false, false));
- Assert.assertTrue("file .cvsignore should be filtered", f.filter(".cvsignore", false, false));
- Assert.assertFalse("file foo.cvsignore shouldn't be filtered", f.filter("foo.cvsignore", false, false));
- Assert.assertTrue("folder bin should be filtered", f.filter("bin", true, false));
- Assert.assertFalse("file bin shouldn't be filtered", f.filter("bin", false, false));
+ f.setFilters("*.class, .cvsignore, bin/"); //$NON-NLS-1$
+ Assert.assertTrue("file foo.class should be filtered", f.filter("foo.class", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file foo.java shouldn't be filtered", f.filter("foo.java", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertTrue("file .cvsignore should be filtered", f.filter(".cvsignore", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file foo.cvsignore shouldn't be filtered", f.filter("foo.cvsignore", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertTrue("folder bin should be filtered", f.filter("bin", true, false)); //$NON-NLS-1$ //$NON-NLS-2$
+ Assert.assertFalse("file bin shouldn't be filtered", f.filter("bin", false, false)); //$NON-NLS-1$ //$NON-NLS-2$
}
public void testVerify() {
diff --git a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/StreamMergerTest.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/StreamMergerTest.java
index 3e3884e09..edd4d17d9 100644
--- a/tests/org.eclipse.compare.tests/JUnit Tests/org/eclipse/compare/tests/StreamMergerTest.java
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/StreamMergerTest.java
@@ -1,9 +1,13 @@
-/*
- * Created on Apr 12, 2004
- *
- * To change the template for this generated file go to
- * Window - Preferences - Java - Code Generation - Code and Comments
- */
+/*******************************************************************************
+ * Copyright (c) 2000, 2004 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Common Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/cpl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
package org.eclipse.compare.tests;
import java.io.ByteArrayInputStream;
diff --git a/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/UITest.java b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/UITest.java
new file mode 100644
index 000000000..5128dba03
--- /dev/null
+++ b/tests/org.eclipse.compare.tests/src/org/eclipse/compare/tests/UITest.java
@@ -0,0 +1,24 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2004 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Common Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/cpl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.compare.tests;
+
+import junit.framework.TestCase;
+
+public class UITest extends TestCase {
+
+ public UITest(String name) {
+ super(name);
+ }
+
+ public void testUI() {
+ // intentionally left empty
+ }
+}

Back to the top