Skip to main content
aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2012-11-15 12:15:06 +0000
committerHenrik Rentz-Reichert2012-11-15 12:15:06 +0000
commit557a4e516e25c5fce5c2baaad46b1b8c95326879 (patch)
treeeadd9b415f9a6c03064c22fe11490f66811344f6 /tests
parent1f4d6065eb8ab9a2454396482c8f50e66e49976f (diff)
downloadorg.eclipse.etrice-557a4e516e25c5fce5c2baaad46b1b8c95326879.tar.gz
org.eclipse.etrice-557a4e516e25c5fce5c2baaad46b1b8c95326879.tar.xz
org.eclipse.etrice-557a4e516e25c5fce5c2baaad46b1b8c95326879.zip
[core.etphys] initial version of physical model
Diffstat (limited to 'tests')
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/.classpath8
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/.gitignore1
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/.project28
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/META-INF/MANIFEST.MF22
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/about.html28
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/bin/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.classbin0 -> 1649 bytes
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/build.properties5
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/org.eclipse.etrice.core.etphys.tests.launch13
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.java45
-rw-r--r--tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysUiInjectorProvider.java16
10 files changed, 166 insertions, 0 deletions
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/.classpath b/tests/org.eclipse.etrice.core.etphys.tests/.classpath
new file mode 100644
index 000000000..e5fbd3dd2
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/.classpath
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="src" path="src-gen"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/.gitignore b/tests/org.eclipse.etrice.core.etphys.tests/.gitignore
new file mode 100644
index 000000000..092357e47
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/.gitignore
@@ -0,0 +1 @@
+bin
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/.project b/tests/org.eclipse.etrice.core.etphys.tests/.project
new file mode 100644
index 000000000..ac112f1ea
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/.project
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.eclipse.etrice.core.etphys.tests</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ </natures>
+</projectDescription>
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/META-INF/MANIFEST.MF b/tests/org.eclipse.etrice.core.etphys.tests/META-INF/MANIFEST.MF
new file mode 100644
index 000000000..089c1e7cc
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/META-INF/MANIFEST.MF
@@ -0,0 +1,22 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: org.eclipse.etrice.core.etphys.tests
+Bundle-Vendor: My Company
+Bundle-Version: 1.0.0.qualifier
+Bundle-SymbolicName: org.eclipse.etrice.core.etphys.tests; singleton:=true
+Bundle-ActivationPolicy: lazy
+Require-Bundle: org.eclipse.etrice.core.etphys,
+ org.eclipse.etrice.core.etphys.ui,
+ org.eclipse.core.runtime,
+ org.eclipse.xtext.junit4,
+ org.eclipse.ui.workbench;resolution:=optional
+Import-Package: org.apache.log4j,
+ org.junit;version="4.5.0",
+ org.junit.runner;version="4.5.0",
+ org.junit.runner.manipulation;version="4.5.0",
+ org.junit.runner.notification;version="4.5.0",
+ org.junit.runners;version="4.5.0",
+ org.junit.runners.model;version="4.5.0",
+ org.hamcrest.core
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Export-Package: org.eclipse.etrice.core.etphys
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/about.html b/tests/org.eclipse.etrice.core.etphys.tests/about.html
new file mode 100644
index 000000000..f47dbddbb
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/about.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+
+<p>June 5, 2006</p>
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content. Check the Redistributor's license that was
+provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html> \ No newline at end of file
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/bin/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.class b/tests/org.eclipse.etrice.core.etphys.tests/bin/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.class
new file mode 100644
index 000000000..fed38c28f
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/bin/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.class
Binary files differ
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/build.properties b/tests/org.eclipse.etrice.core.etphys.tests/build.properties
new file mode 100644
index 000000000..e10dcceb6
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/build.properties
@@ -0,0 +1,5 @@
+source.. = src/,\
+ src-gen/
+bin.includes = META-INF/,\
+ .,\
+ plugin.xml \ No newline at end of file
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/org.eclipse.etrice.core.etphys.tests.launch b/tests/org.eclipse.etrice.core.etphys.tests/org.eclipse.etrice.core.etphys.tests.launch
new file mode 100644
index 000000000..253b6977a
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/org.eclipse.etrice.core.etphys.tests.launch
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.jdt.junit.launchconfig">
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+<listEntry value="/org.eclipse.etrice.core.etphys.tests"/>
+</listAttribute>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+<listEntry value="4"/>
+</listAttribute>
+<stringAttribute key="org.eclipse.jdt.junit.CONTAINER" value="=org.eclipse.etrice.core.etphys.tests"/>
+<booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
+<stringAttribute key="org.eclipse.jdt.junit.TEST_KIND" value="org.eclipse.jdt.junit.loader.junit4"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.eclipse.etrice.core.etphys.tests"/>
+</launchConfiguration>
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.java b/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.java
new file mode 100644
index 000000000..acc7d319b
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysInjectorProvider.java
@@ -0,0 +1,45 @@
+/*
+* generated by Xtext
+*/
+package org.eclipse.etrice.core.etphys;
+
+import org.eclipse.xtext.junit4.GlobalRegistries;
+import org.eclipse.xtext.junit4.GlobalRegistries.GlobalStateMemento;
+import org.eclipse.xtext.junit4.IInjectorProvider;
+import org.eclipse.xtext.junit4.IRegistryConfigurator;
+
+import com.google.inject.Injector;
+
+public class ETPhysInjectorProvider implements IInjectorProvider, IRegistryConfigurator {
+
+ protected GlobalStateMemento stateBeforeInjectorCreation;
+ protected GlobalStateMemento stateAfterInjectorCreation;
+ protected Injector injector;
+
+ static {
+ GlobalRegistries.initializeDefaults();
+ }
+
+ public Injector getInjector()
+ {
+ if (injector == null) {
+ stateBeforeInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
+ this.injector = internalCreateInjector();
+ stateAfterInjectorCreation = GlobalRegistries.makeCopyOfGlobalState();
+ }
+ return injector;
+ }
+
+ protected Injector internalCreateInjector() {
+ return new ETPhysStandaloneSetup().createInjectorAndDoEMFRegistration();
+ }
+
+ public void restoreRegistry() {
+ stateBeforeInjectorCreation.restoreGlobalState();
+ }
+
+ public void setupRegistry() {
+ getInjector();
+ stateAfterInjectorCreation.restoreGlobalState();
+ }
+}
diff --git a/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysUiInjectorProvider.java b/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysUiInjectorProvider.java
new file mode 100644
index 000000000..e7e1d96d1
--- /dev/null
+++ b/tests/org.eclipse.etrice.core.etphys.tests/src-gen/org/eclipse/etrice/core/etphys/ETPhysUiInjectorProvider.java
@@ -0,0 +1,16 @@
+/*
+* generated by Xtext
+*/
+package org.eclipse.etrice.core.etphys;
+
+import org.eclipse.xtext.junit4.IInjectorProvider;
+
+import com.google.inject.Injector;
+
+public class ETPhysUiInjectorProvider implements IInjectorProvider {
+
+ public Injector getInjector() {
+ return org.eclipse.etrice.core.etphys.ui.internal.ETPhysActivator.getInstance().getInjector("org.eclipse.etrice.core.etphys.ETPhys");
+ }
+
+}

Back to the top