Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormtaal2010-02-07 05:47:33 -0500
committermtaal2010-02-07 05:47:33 -0500
commit76d3b2cd1cede054d0e9301bd9d1c0ea517043f7 (patch)
tree1418610c6ff205026d9a7dd1c7536dd720a71188
parent560cb8e839cbc6c4415bbde291490752413b27ed (diff)
downloadorg.eclipse.emf.teneo-76d3b2cd1cede054d0e9301bd9d1c0ea517043f7.tar.gz
org.eclipse.emf.teneo-76d3b2cd1cede054d0e9301bd9d1c0ea517043f7.tar.xz
org.eclipse.emf.teneo-76d3b2cd1cede054d0e9301bd9d1c0ea517043f7.zip
Enabled testing of eclipselink
-rw-r--r--tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/AllTests.launch16
-rw-r--r--tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/META-INF/MANIFEST.MF21
-rw-r--r--tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/AllTests.java3
-rw-r--r--tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/EclipseLinkResourceTest.java9
4 files changed, 40 insertions, 9 deletions
diff --git a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/AllTests.launch b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/AllTests.launch
new file mode 100644
index 000000000..26b2aa1d9
--- /dev/null
+++ b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/AllTests.launch
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.jdt.junit.launchconfig">
+<stringAttribute key="bad_container_name" value="/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/AllTests."/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+<listEntry value="/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/AllTests.java"/>
+</listAttribute>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+<listEntry value="1"/>
+</listAttribute>
+<stringAttribute key="org.eclipse.jdt.junit.CONTAINER" value=""/>
+<booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
+<stringAttribute key="org.eclipse.jdt.junit.TESTNAME" value=""/>
+<stringAttribute key="org.eclipse.jdt.junit.TEST_KIND" value="org.eclipse.jdt.junit.loader.junit3"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests.AllTests"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests"/>
+</launchConfiguration>
diff --git a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/META-INF/MANIFEST.MF b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/META-INF/MANIFEST.MF
index 31c8761e9..fa6a198b1 100644
--- a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/META-INF/MANIFEST.MF
+++ b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/META-INF/MANIFEST.MF
@@ -4,16 +4,21 @@ Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests; singleton:=true
Bundle-Version: 1.0.0.qualifier
Bundle-Localization: plugin
-Require-Bundle: org.eclipse.core.runtime,
- org.eclipse.core.resources,
+Require-Bundle: org.eclipse.core.resources,
org.eclipse.emf.ecore,
- org.eclipse.emf.ecore.xmi,
- org.junit,
- javax.persistence;bundle-version="1.99.0",
- org.eclipse.emf.teneo.eclipselink.examples.library,
- org.eclipse.emf.teneo.eclipselink;bundle-version="1.0.0",
- org.apache.derby;bundle-version="10.1.2"
+ org.eclipse.emf.ecore.xmi;bundle-version="[2.5.0,3.0.0)",
+ org.junit;bundle-version="[3.8.0,4.0.0)",
+ javax.persistence;bundle-version="[2.0.0,3.0.0)",
+ org.eclipse.emf.teneo.eclipselink.examples.library;bundle-version="[1.0.0,2.0.0)",
+ org.eclipse.emf.teneo.eclipselink;bundle-version="[1.0.0,2.0.0)",
+ org.apache.derby;bundle-version="[10.1.2,11.0.0)",
+ org.eclipse.persistence.jpa;bundle-version="[2.0.0,3.0.0)",
+ org.eclipse.persistence.asm;bundle-version="[2.0.0,3.0.0)",
+ org.eclipse.persistence.antlr;bundle-version="[2.0.0,3.0.0)"
Bundle-ActivationPolicy: lazy
Bundle-Vendor: %providerName
Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Import-Package: org.eclipse.core.runtime;version="[3.4.0,4.0.0)",
+ org.eclipse.core.runtime.jobs,
+ org.hsqldb;version="1.8.1"
diff --git a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/AllTests.java b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/AllTests.java
index ce16f684e..d667248bf 100644
--- a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/AllTests.java
+++ b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/AllTests.java
@@ -20,7 +20,8 @@ public class AllTests {
TestSuite suite = new TestSuite("TestSuite for EclipseLinkResourceImpl");
// $JUnit-BEGIN$
suite.addTestSuite(EclipseLinkResourceTest.class);
- suite.addTestSuite(EclipseLinkAndXMIResourceTest.class);
+ // disabled following tests as it requires an open workspace
+ // suite.addTestSuite(EclipseLinkAndXMIResourceTest.class);
// $JUnit-END$
return suite;
}
diff --git a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/EclipseLinkResourceTest.java b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/EclipseLinkResourceTest.java
index 70cb99a45..86740bd38 100644
--- a/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/EclipseLinkResourceTest.java
+++ b/tests/org.eclipse.emf.teneo.eclipselink.examples.library.orm.tests/src/org/eclipse/emf/teneo/eclipselink/examples/library/orm/tests/resource/EclipseLinkResourceTest.java
@@ -22,6 +22,7 @@ import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl;
import org.eclipse.emf.teneo.eclipselink.examples.library.Library;
import org.eclipse.emf.teneo.eclipselink.examples.library.LibraryPackage;
import org.eclipse.emf.teneo.eclipselink.examples.library.impl.LibraryImpl;
+import org.eclipse.emf.teneo.eclipselink.resource.EclipseLinkResourceFactoryImpl;
import org.eclipse.emf.teneo.eclipselink.resource.EclipseLinkResourceImpl;
import org.eclipse.emf.teneo.eclipselink.resource.EclipseLinkURIUtil;
@@ -53,6 +54,10 @@ public class EclipseLinkResourceTest extends AbstractEclipseLinkTest {
// save library model instance in database
ResourceSet resourceSet1 = new ResourceSetImpl();
resourceSet1.getLoadOptions().putAll(getTestPersistenceUnitProperties(this.getClass().getClassLoader()));
+
+ resourceSet1.getResourceFactoryRegistry().getProtocolToFactoryMap().put("eclipselink",
+ new EclipseLinkResourceFactoryImpl());
+
resource1 = resourceSet1.createResource(uri);
assertTrue(resource1 instanceof EclipseLinkResourceImpl);
@@ -69,7 +74,11 @@ public class EclipseLinkResourceTest extends AbstractEclipseLinkTest {
// load second library model instance from database
ResourceSet resourceSet2 = new ResourceSetImpl();
+
+ resourceSet2.getResourceFactoryRegistry().getProtocolToFactoryMap().put("eclipselink",
+ new EclipseLinkResourceFactoryImpl());
resourceSet2.getLoadOptions().putAll(getTestPersistenceUnitProperties(this.getClass().getClassLoader()));
+
resource2 = resourceSet2.getResource(uri, true);
assertTrue(resource2 instanceof EclipseLinkResourceImpl);

Back to the top