aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenoit Maggi2018-06-08 06:10:54 -0400
committerQuentin Le Menez2018-06-11 04:35:17 -0400
commit6673b76c929479c9743e1732eb697884b768608c (patch)
tree8e8adf5be027e263ef9bb91d311237184750755f
parent510aa42d6fda6f73d8c5390b7387dbd8d7524fc5 (diff)
downloadorg.eclipse.papyrus-6673b76c929479c9743e1732eb697884b768608c.zip
org.eclipse.papyrus-6673b76c929479c9743e1732eb697884b768608c.tar.gz
org.eclipse.papyrus-6673b76c929479c9743e1732eb697884b768608c.tar.xz
Bug 535680 - [Tests] Validate model related to composite diagram
- add ModelValidationTest to validate the models - remove duplicate elements in pom.xml - remove unused import Change-Id: I6d4c9487b33f68b91de1bc934d66456e7a71b237 Signed-off-by: Benoit Maggi <benoit.maggi@cea.fr>
-rw-r--r--tests/junit/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.tests/test/org/eclipse/papyrus/infra/core/sasheditor/contentprovider/ISashWindowsContentProviderFacade.java5
-rw-r--r--tests/junit/plugins/infra/gmfdiag/org.eclipse.papyrus.infra.gmfdiag.welcome.tests/src/org/eclipse/papyrus/infra/gmfdiag/welcome/tests/WelcomeModelElementTest.java3
-rw-r--r--tests/junit/plugins/infra/services/org.eclipse.papyrus.infra.services.edit.tests/src/org/eclipse/papyrus/infra/services/edit/tests/commands/TestConfigureFeatureListCommandFactory.java1
-rwxr-xr-xtests/junit/plugins/infra/viewpoints/pom.xml1
-rwxr-xr-xtests/junit/plugins/uml/assistants/pom.xml2
-rwxr-xr-xtests/junit/plugins/uml/decoratormodel/pom.xml2
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/META-INF/MANIFEST.MF5
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/AllTests.java4
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/resources/ModelValidationTest.java78
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/bug/TestMessageCreate_379661.java2
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/canonical/TestTopNode.java1
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.tests/src/org/eclipse/papyrus/uml/diagram/tests/createFromPalette/AbstractCreateNodeFromPaletteTest.java3
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java1
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteAll_Test.java1
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java1
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailColumns_Test.java1
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailRows_Test.java1
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.tests/src/org/eclipse/papyrus/uml/nattable/tests/bugs/MoveElementInSynchronizedTableTest.java1
-rwxr-xr-xtests/junit/plugins/uml/nattable/pom.xml1
-rw-r--r--tests/junit/plugins/uml/org.eclipse.papyrus.uml.service.types.tests/src/org/eclipse/papyrus/uml/service/types/tests/creation/CreatePureUMLElementTest.java77
20 files changed, 88 insertions, 103 deletions
diff --git a/tests/junit/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.tests/test/org/eclipse/papyrus/infra/core/sasheditor/contentprovider/ISashWindowsContentProviderFacade.java b/tests/junit/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.tests/test/org/eclipse/papyrus/infra/core/sasheditor/contentprovider/ISashWindowsContentProviderFacade.java
index 99fc363..01f7b91 100644
--- a/tests/junit/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.tests/test/org/eclipse/papyrus/infra/core/sasheditor/contentprovider/ISashWindowsContentProviderFacade.java
+++ b/tests/junit/plugins/infra/core/org.eclipse.papyrus.infra.core.sasheditor.tests/test/org/eclipse/papyrus/infra/core/sasheditor/contentprovider/ISashWindowsContentProviderFacade.java
@@ -16,11 +16,8 @@ package org.eclipse.papyrus.infra.core.sasheditor.contentprovider;
import java.util.Map;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IAbstractPanelModel;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IPageModel;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ISashWindowsContentProvider;
-import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.ITabFolderModel;
import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.simple.SimpleSashWindowsContentProvider;
+import org.eclipse.papyrus.infra.core.sasheditor.editor.ISashWindowsContainer;
import org.eclipse.papyrus.infra.core.sasheditor.pagesmodel.IModelExp;
import org.eclipse.papyrus.infra.core.sasheditor.pagesmodel.NotFoundException;
import org.eclipse.papyrus.infra.core.sasheditor.pagesmodel.Page;
diff --git a/tests/junit/plugins/infra/gmfdiag/org.eclipse.papyrus.infra.gmfdiag.welcome.tests/src/org/eclipse/papyrus/infra/gmfdiag/welcome/tests/WelcomeModelElementTest.java b/tests/junit/plugins/infra/gmfdiag/org.eclipse.papyrus.infra.gmfdiag.welcome.tests/src/org/eclipse/papyrus/infra/gmfdiag/welcome/tests/WelcomeModelElementTest.java
index dafd179..d3f03a7 100644
--- a/tests/junit/plugins/infra/gmfdiag/org.eclipse.papyrus.infra.gmfdiag.welcome.tests/src/org/eclipse/papyrus/infra/gmfdiag/welcome/tests/WelcomeModelElementTest.java
+++ b/tests/junit/plugins/infra/gmfdiag/org.eclipse.papyrus.infra.gmfdiag.welcome.tests/src/org/eclipse/papyrus/infra/gmfdiag/welcome/tests/WelcomeModelElementTest.java
@@ -34,9 +34,8 @@ import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.emf.ecore.util.EcoreUtil;
import org.eclipse.emf.transaction.RecordingCommand;
-import org.eclipse.papyrus.infra.gmfdiag.representation.PapyrusDiagram;
-import org.eclipse.papyrus.infra.architecture.representation.PapyrusRepresentationKind;
import org.eclipse.papyrus.infra.editor.welcome.tests.AbstractWelcomePageTest;
+import org.eclipse.papyrus.infra.gmfdiag.representation.PapyrusDiagram;
import org.eclipse.papyrus.infra.gmfdiag.welcome.internal.modelelements.NotationObservable;
import org.eclipse.papyrus.infra.gmfdiag.welcome.internal.modelelements.WelcomeModelElement;
import org.eclipse.papyrus.infra.gmfdiag.welcome.internal.modelelements.WelcomeModelElementFactory;
diff --git a/tests/junit/plugins/infra/services/org.eclipse.papyrus.infra.services.edit.tests/src/org/eclipse/papyrus/infra/services/edit/tests/commands/TestConfigureFeatureListCommandFactory.java b/tests/junit/plugins/infra/services/org.eclipse.papyrus.infra.services.edit.tests/src/org/eclipse/papyrus/infra/services/edit/tests/commands/TestConfigureFeatureListCommandFactory.java
index fd5b49c..14227f7 100644
--- a/tests/junit/plugins/infra/services/org.eclipse.papyrus.infra.services.edit.tests/src/org/eclipse/papyrus/infra/services/edit/tests/commands/TestConfigureFeatureListCommandFactory.java
+++ b/tests/junit/plugins/infra/services/org.eclipse.papyrus.infra.services.edit.tests/src/org/eclipse/papyrus/infra/services/edit/tests/commands/TestConfigureFeatureListCommandFactory.java
@@ -19,7 +19,6 @@ import org.eclipse.gmf.runtime.emf.type.core.requests.IEditCommandRequest;
import org.eclipse.papyrus.infra.core.services.ServiceException;
import org.eclipse.papyrus.infra.services.edit.commands.ConfigureFeatureListCommandFactory;
import org.eclipse.papyrus.infra.services.edit.commands.IConfigureCommandFactory;
-import org.eclipse.papyrus.infra.services.edit.internal.ElementEditService;
import org.eclipse.papyrus.infra.services.edit.service.IElementEditService;
import org.eclipse.papyrus.infra.services.edit.tests.AbstractTestElementEditService;
import org.junit.Before;
diff --git a/tests/junit/plugins/infra/viewpoints/pom.xml b/tests/junit/plugins/infra/viewpoints/pom.xml
index ada1e0d..b727e99 100755
--- a/tests/junit/plugins/infra/viewpoints/pom.xml
+++ b/tests/junit/plugins/infra/viewpoints/pom.xml
@@ -8,7 +8,6 @@
<artifactId>org.eclipse.papyrus.infra.tests.releng</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
- <groupId>org.eclipse.papyrus.tests</groupId>
<artifactId>org.eclipse.papyrus.infra.viewpoints.tests.releng</artifactId>
<version>1.2.0-SNAPSHOT</version>
<packaging>pom</packaging>
diff --git a/tests/junit/plugins/uml/assistants/pom.xml b/tests/junit/plugins/uml/assistants/pom.xml
index 2d999dd..f53c11d 100755
--- a/tests/junit/plugins/uml/assistants/pom.xml
+++ b/tests/junit/plugins/uml/assistants/pom.xml
@@ -8,9 +8,7 @@
<artifactId>org.eclipse.papyrus.uml.tests.releng</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
- <groupId>org.eclipse.papyrus.tests</groupId>
<artifactId>org.eclipse.papyrus.uml.assistants.tests.releng</artifactId>
- <version>0.0.1-SNAPSHOT</version>
<packaging>pom</packaging>
<description>Tests for the Papyrus uml assistants</description>
diff --git a/tests/junit/plugins/uml/decoratormodel/pom.xml b/tests/junit/plugins/uml/decoratormodel/pom.xml
index 9d9ece1..c131e24 100755
--- a/tests/junit/plugins/uml/decoratormodel/pom.xml
+++ b/tests/junit/plugins/uml/decoratormodel/pom.xml
@@ -8,9 +8,7 @@
<artifactId>org.eclipse.papyrus.uml.tests.releng</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
- <groupId>org.eclipse.papyrus.tests</groupId>
<artifactId>org.eclipse.papyrus.uml.decoratormodel.tests.releng</artifactId>
- <version>0.0.1-SNAPSHOT</version>
<packaging>pom</packaging>
<description>Tests for uml decoratormodel</description>
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/META-INF/MANIFEST.MF b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/META-INF/MANIFEST.MF
index 9e04a91..857c8a8 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/META-INF/MANIFEST.MF
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/META-INF/MANIFEST.MF
@@ -20,7 +20,10 @@ Require-Bundle: org.eclipse.ui,
org.eclipse.papyrus.infra.ui;bundle-version="[2.0.0,3.0.0)",
org.eclipse.papyrus.infra.core.sashwindows.di;bundle-version="[1.2.0,2.0.0)"
Export-Package: org.eclipse.papyrus.uml.diagram.composite.test,
- org.eclipse.papyrus.uml.diagram.composite.test.canonical
+ org.eclipse.papyrus.uml.diagram.composite.test.canonical,
+ org.eclipse.papyrus.uml.diagram.composite.test.model,
+ org.eclipse.papyrus.uml.diagram.composite.test.resources,
+ org.eclipse.papyrus.uml.diagram.composite.tests.copyPaste
Bundle-Vendor: %providerName
Bundle-ActivationPolicy: lazy
Bundle-Version: 1.2.100.qualifier
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/AllTests.java b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/AllTests.java
index 7dee471..41624e3 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/AllTests.java
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/AllTests.java
@@ -18,6 +18,7 @@ import org.eclipse.papyrus.junit.framework.classification.ClassificationSuite;
import org.eclipse.papyrus.junit.framework.classification.ClassificationSuite.DynamicClasses;
import org.eclipse.papyrus.uml.diagram.composite.test.canonical.AllCanonicalTests;
import org.eclipse.papyrus.uml.diagram.composite.test.model.AllModelTests;
+import org.eclipse.papyrus.uml.diagram.composite.test.resources.ModelValidationTest;
import org.eclipse.papyrus.uml.diagram.composite.tests.copyPaste.ConstraintCopyPasteTest;
import org.junit.runner.RunWith;
import org.junit.runners.Suite.SuiteClasses;
@@ -31,7 +32,8 @@ import org.junit.runners.Suite.SuiteClasses;
AllCanonicalTests.class,
RoundedCompartmentTest.class,
AllModelTests.class,
- ConstraintCopyPasteTest.class
+ ConstraintCopyPasteTest.class,
+ ModelValidationTest.class
})
@DynamicClasses("org.eclipse.papyrus.uml.diagram.composite.test.AllGenTests")
public class AllTests {
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/resources/ModelValidationTest.java b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/resources/ModelValidationTest.java
new file mode 100644
index 0000000..23ff624
--- /dev/null
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.composite.tests/test/org/eclipse/papyrus/uml/diagram/composite/test/resources/ModelValidationTest.java
@@ -0,0 +1,78 @@
+/*****************************************************************************
+ * Copyright (c) 2018 CEA and others.
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - Initial API and implementation
+ *
+ *****************************************************************************/
+
+package org.eclipse.papyrus.uml.diagram.composite.test.resources;
+
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.emf.common.util.Diagnostic;
+import org.eclipse.emf.common.util.URI;
+import org.eclipse.emf.ecore.resource.Resource;
+import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl;
+import org.eclipse.emf.ecore.util.Diagnostician;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized;
+import org.junit.runners.Parameterized.Parameters;
+
+/**
+ * This is a parameterized test to validate all model in the plugin
+ *
+ * @author Benoit Maggi
+ */
+@SuppressWarnings("nls")
+@RunWith(Parameterized.class)
+public class ModelValidationTest {
+
+ @Parameters
+ public static Collection<Object[]> data() {
+ return Arrays.asList(new Object[][] {
+ {"/model/CompositeStructure.paletteconfiguration"},
+ {"/model/compositediagram.elementtypesconfigurations"},
+ {"/model/compositediagram.gmfgen"},
+ });
+ }
+
+ private String modelPath;
+
+ public ModelValidationTest(String modelPath) {
+ this.modelPath = modelPath;
+ }
+
+ /**
+ * Validate the model with the rules defined in the meta-model tooling
+ */
+ @Test
+ public void validateModel() {
+ String fullPath = "org.eclipse.papyrus.uml.diagram.composite"+ this.modelPath;
+ URI modelPlatformURI = URI.createPlatformPluginURI(fullPath, true);
+ Resource resource = new ResourceSetImpl().getResource(modelPlatformURI, true);
+ Diagnostic diagnostic = Diagnostician.INSTANCE.validate(resource.getContents().get(0));
+ Assert.assertEquals("The "+modelPath+" model is invalid "+print(diagnostic), Diagnostic.OK, diagnostic.getSeverity());
+ }
+
+ // FIXME : Something should exist in API to do that
+ private String print(Diagnostic diagnostic) {
+ List<Diagnostic> children = diagnostic.getChildren();
+ StringBuilder stringBuilder = new StringBuilder(diagnostic.getMessage());
+ for (Diagnostic diagnosticChildren : children) {
+ stringBuilder.append("\n"); //$NON-NLS-1$
+ stringBuilder.append(diagnosticChildren.getMessage());
+ }
+ return stringBuilder.toString();
+ }
+
+}
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/bug/TestMessageCreate_379661.java b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/bug/TestMessageCreate_379661.java
index c18f3c9..0bd5934 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/bug/TestMessageCreate_379661.java
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/bug/TestMessageCreate_379661.java
@@ -18,7 +18,6 @@ import static org.junit.Assert.assertTrue;
import org.eclipse.draw2d.IFigure;
import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.RectangleFigure;
import org.eclipse.draw2d.geometry.Dimension;
import org.eclipse.draw2d.geometry.Point;
import org.eclipse.draw2d.geometry.Rectangle;
@@ -41,7 +40,6 @@ import org.eclipse.papyrus.uml.diagram.sequence.providers.UMLElementTypes;
import org.eclipse.papyrus.uml.diagram.sequence.tests.ISequenceDiagramTestsConstants;
import org.eclipse.papyrus.uml.diagram.sequence.tests.canonical.CreateSequenceDiagramCommand;
import org.eclipse.papyrus.uml.diagram.sequence.tests.canonical.TestLink;
-import org.eclipse.uml2.uml.Lifeline;
import org.junit.Test;
/**
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/canonical/TestTopNode.java b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/canonical/TestTopNode.java
index d466604..24ee224 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/canonical/TestTopNode.java
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.sequence.tests/src/org/eclipse/papyrus/uml/diagram/sequence/tests/canonical/TestTopNode.java
@@ -45,7 +45,6 @@ import org.eclipse.papyrus.infra.core.services.ServiceException;
import org.eclipse.papyrus.infra.ui.util.ServiceUtilsForActionHandlers;
import org.eclipse.papyrus.uml.diagram.common.Activator;
import org.eclipse.papyrus.uml.diagram.tests.canonical.AbstractPapyrusTestCase;
-import org.eclipse.swt.widgets.Display;
import org.eclipse.uml2.uml.Element;
import org.eclipse.uml2.uml.Package;
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.tests/src/org/eclipse/papyrus/uml/diagram/tests/createFromPalette/AbstractCreateNodeFromPaletteTest.java b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.tests/src/org/eclipse/papyrus/uml/diagram/tests/createFromPalette/AbstractCreateNodeFromPaletteTest.java
index 6c05765..dc8cfa8 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.tests/src/org/eclipse/papyrus/uml/diagram/tests/createFromPalette/AbstractCreateNodeFromPaletteTest.java
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.tests/src/org/eclipse/papyrus/uml/diagram/tests/createFromPalette/AbstractCreateNodeFromPaletteTest.java
@@ -17,7 +17,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
import java.util.Iterator;
-import java.util.List;
import org.eclipse.gef.EditPart;
import org.eclipse.gef.commands.Command;
@@ -33,8 +32,8 @@ import org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest;
import org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequestFactory;
import org.eclipse.gmf.runtime.emf.type.core.IElementType;
import org.eclipse.gmf.runtime.notation.View;
-import org.eclipse.papyrus.infra.gmfdiag.common.updater.DiagramUpdater;
import org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.IMaskManagedLabelEditPolicy;
+import org.eclipse.papyrus.infra.gmfdiag.common.updater.DiagramUpdater;
import org.eclipse.papyrus.uml.diagram.common.editparts.NamedElementEditPart;
import org.eclipse.papyrus.uml.diagram.common.editparts.UMLCompartmentEditPart;
import org.eclipse.swt.widgets.Display;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
index 93fa8bd..3b010d6 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.generic.tests/src/org/eclipse/papyrus/uml/nattable/generic/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
@@ -15,7 +15,6 @@ package org.eclipse.papyrus.uml.nattable.generic.tests.paste.overwrite;
import org.eclipse.nebula.widgets.nattable.NatTable;
import org.eclipse.nebula.widgets.nattable.selection.command.ClearAllSelectionsCommand;
-import org.eclipse.nebula.widgets.nattable.selection.command.SelectCellCommand;
import org.eclipse.nebula.widgets.nattable.selection.command.SelectColumnCommand;
import org.eclipse.papyrus.infra.nattable.manager.table.NattableModelManager;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteAll_Test.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteAll_Test.java
index 19668a3..beae417 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteAll_Test.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteAll_Test.java
@@ -13,7 +13,6 @@
package org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests.paste.overwrite;
-import org.eclipse.nebula.widgets.nattable.selection.command.SelectCellCommand;
import org.eclipse.nebula.widgets.nattable.selection.command.SelectColumnCommand;
import org.eclipse.papyrus.infra.nattable.manager.table.NattableModelManager;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
index 3562bff..9506688 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteByOneLine_Test.java
@@ -15,7 +15,6 @@ package org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests.paste.overwr
import org.eclipse.nebula.widgets.nattable.NatTable;
import org.eclipse.nebula.widgets.nattable.selection.command.ClearAllSelectionsCommand;
-import org.eclipse.nebula.widgets.nattable.selection.command.SelectCellCommand;
import org.eclipse.nebula.widgets.nattable.selection.command.SelectColumnCommand;
import org.eclipse.papyrus.infra.nattable.manager.table.NattableModelManager;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailColumns_Test.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailColumns_Test.java
index 08af5cc..230750a 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailColumns_Test.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailColumns_Test.java
@@ -14,7 +14,6 @@
package org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests.paste.overwrite;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.nebula.widgets.nattable.selection.command.SelectCellCommand;
import org.eclipse.nebula.widgets.nattable.selection.command.SelectColumnCommand;
import org.eclipse.papyrus.infra.nattable.manager.table.NattableModelManager;
import org.eclipse.papyrus.infra.nattable.messages.Messages;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailRows_Test.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailRows_Test.java
index 453f6f1..c258d7d 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailRows_Test.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests/src/org/eclipse/papyrus/uml/nattable/stereotyped/elements/tests/paste/overwrite/PasteColumnsOverwriteFailRows_Test.java
@@ -14,7 +14,6 @@
package org.eclipse.papyrus.uml.nattable.stereotyped.elements.tests.paste.overwrite;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.nebula.widgets.nattable.selection.command.SelectCellCommand;
import org.eclipse.nebula.widgets.nattable.selection.command.SelectColumnCommand;
import org.eclipse.papyrus.infra.nattable.manager.table.NattableModelManager;
import org.eclipse.papyrus.infra.nattable.messages.Messages;
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.tests/src/org/eclipse/papyrus/uml/nattable/tests/bugs/MoveElementInSynchronizedTableTest.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.tests/src/org/eclipse/papyrus/uml/nattable/tests/bugs/MoveElementInSynchronizedTableTest.java
index d1194951..c81bbf9 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.tests/src/org/eclipse/papyrus/uml/nattable/tests/bugs/MoveElementInSynchronizedTableTest.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.tests/src/org/eclipse/papyrus/uml/nattable/tests/bugs/MoveElementInSynchronizedTableTest.java
@@ -29,7 +29,6 @@ import org.eclipse.papyrus.infra.nattable.manager.table.TreeNattableModelManager
import org.eclipse.papyrus.infra.nattable.model.nattable.Table;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxis.IAxis;
import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxisconfiguration.TreeFillingConfiguration;
-import org.eclipse.papyrus.infra.nattable.model.nattable.nattableaxisprovider.NattableaxisproviderPackage;
import org.eclipse.papyrus.infra.nattable.tree.CollapseAndExpandActionsEnum;
import org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils;
import org.eclipse.papyrus.infra.services.edit.service.IElementEditService;
diff --git a/tests/junit/plugins/uml/nattable/pom.xml b/tests/junit/plugins/uml/nattable/pom.xml
index df6c468..3cea919 100755
--- a/tests/junit/plugins/uml/nattable/pom.xml
+++ b/tests/junit/plugins/uml/nattable/pom.xml
@@ -7,7 +7,6 @@
<artifactId>org.eclipse.papyrus.uml.tests.releng</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
- <groupId>org.eclipse.papyrus.tests</groupId>
<artifactId>org.eclipse.papyrus.uml.nattable.main.test</artifactId>
<version>1.2.0-SNAPSHOT</version>
<packaging>pom</packaging>
diff --git a/tests/junit/plugins/uml/org.eclipse.papyrus.uml.service.types.tests/src/org/eclipse/papyrus/uml/service/types/tests/creation/CreatePureUMLElementTest.java b/tests/junit/plugins/uml/org.eclipse.papyrus.uml.service.types.tests/src/org/eclipse/papyrus/uml/service/types/tests/creation/CreatePureUMLElementTest.java
index 9f698c6..1cd4177 100644
--- a/tests/junit/plugins/uml/org.eclipse.papyrus.uml.service.types.tests/src/org/eclipse/papyrus/uml/service/types/tests/creation/CreatePureUMLElementTest.java
+++ b/tests/junit/plugins/uml/org.eclipse.papyrus.uml.service.types.tests/src/org/eclipse/papyrus/uml/service/types/tests/creation/CreatePureUMLElementTest.java
@@ -18,7 +18,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.fail;
import java.io.IOException;
-import java.util.Collections;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IProject;
@@ -38,18 +37,8 @@ import org.eclipse.emf.transaction.TransactionalEditingDomain;
import org.eclipse.gmf.runtime.common.core.command.ICommand;
import org.eclipse.gmf.runtime.emf.type.core.IHintedType;
import org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest;
-import org.eclipse.papyrus.infra.core.editor.ModelSetServiceFactory;
-import org.eclipse.papyrus.infra.core.resource.EditingDomainServiceFactory;
import org.eclipse.papyrus.infra.core.resource.ModelMultiException;
import org.eclipse.papyrus.infra.core.resource.ModelSet;
-import org.eclipse.papyrus.infra.core.resource.ModelsReader;
-import org.eclipse.papyrus.infra.core.services.ExtensionServicesRegistry;
-import org.eclipse.papyrus.infra.core.services.ServiceDescriptor;
-import org.eclipse.papyrus.infra.core.services.ServiceDescriptor.ServiceTypeKind;
-import org.eclipse.papyrus.infra.core.services.ServiceException;
-import org.eclipse.papyrus.infra.core.services.ServiceStartKind;
-import org.eclipse.papyrus.infra.core.services.ServicesRegistry;
-import org.eclipse.papyrus.infra.core.utils.ServiceUtils;
import org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils;
import org.eclipse.papyrus.infra.services.edit.service.IElementEditService;
import org.eclipse.papyrus.infra.types.core.registries.ElementTypeSetConfigurationRegistry;
@@ -149,72 +138,6 @@ public class CreatePureUMLElementTest extends AbstractPapyrusTest {
}
/**
- * Create Models set from selected file.
- *
- * @return the model set
- */
- private ModelSet initialiseModelSet(URI modelURI) {
- ServicesRegistry service = null;
-
- try {
- service = new ExtensionServicesRegistry();
- } catch (ServiceException e) {
- fail(e.getMessage());
- }
-
- // Override service factory for Model Set
- ServiceDescriptor descriptor = new ServiceDescriptor(ModelSet.class, ModelSetServiceFactory.class.getName(), ServiceStartKind.STARTUP, 10);
- descriptor.setServiceTypeKind(ServiceTypeKind.serviceFactory);
- service.add(descriptor);
-
- // Override factory for editing domain
- descriptor = new ServiceDescriptor(TransactionalEditingDomain.class, EditingDomainServiceFactory.class.getName(), ServiceStartKind.STARTUP, 10, Collections.singletonList(ModelSet.class.getName()));
- descriptor.setServiceTypeKind(ServiceTypeKind.serviceFactory);
- service.add(descriptor);
-
- try {
- service.startServicesByClassKeys(
- ModelSet.class,
- TransactionalEditingDomain.class);
- } catch (ServiceException e) {
- fail(e.getMessage());
- }
-
- ModelSet modelSet = null;
- try {
- modelSet = ServiceUtils.getInstance().getModelSet(service);
- } catch (ServiceException e) {
- // Ignore service exception
- }
-
- // Instantiate a Model set
- if (modelSet == null) {
- modelSet = new ModelSet();
- try {
- ModelSetServiceFactory.setServiceRegistry(modelSet, service);
- } catch (ServiceException e) {
- // Ignore service exception
- }
- }
-
-
-
- // Read all Model from selected file
- ModelsReader modelsReader = new ModelsReader();
- modelsReader.readModel(modelSet);
- try {
- modelSet.loadModels(modelURI);
- } catch (ModelMultiException e) {
- fail(e.getMessage());
- }
-
- // Initialise an editing domain
- modelSet.getTransactionalEditingDomain();
-
- return modelSet;
- }
-
- /**
* Init fields corresponding to element in the test model
*/
private static void initExistingElements() throws Exception {