Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests')
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/.project6
-rwxr-xr-xtests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/META-INF/MANIFEST.MF3
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/pom.xml2
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test-gen/.gitignore2
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/ClassDiagramGenerateTestsWorkflow.xtend103
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/CustomCreateFromPaletteTest.xtend49
-rw-r--r--tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/xtend-gen/.gitignore2
7 files changed, 2 insertions, 165 deletions
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/.project b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/.project
index 1c0f8aca043..3b84e0f66e9 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/.project
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/.project
@@ -25,16 +25,10 @@
<arguments>
</arguments>
</buildCommand>
- <buildCommand>
- <name>org.eclipse.papyrus.dev.tests.framework.builder</name>
- <arguments>
- </arguments>
- </buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.PluginNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.xtext.ui.shared.xtextNature</nature>
- <nature>org.eclipse.papyrus.dev.tests.framework.nature</nature>
</natures>
</projectDescription>
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/META-INF/MANIFEST.MF b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/META-INF/MANIFEST.MF
index fefdf552856..719894a7bbb 100755
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/META-INF/MANIFEST.MF
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/META-INF/MANIFEST.MF
@@ -25,7 +25,6 @@ Require-Bundle: org.eclipse.ui,
org.eclipse.papyrus.uml.tools.utils;bundle-version="[3.3.0,4.0.0)",
org.eclipse.xtend.lib;bundle-version="2.8.3",
org.eclipse.xtext.xbase.lib;bundle-version="2.8.3",
- org.eclipse.papyrus.tests.framework;bundle-version="[1.2.0,2.0.0)",
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)",
org.eclipse.papyrus.uml.service.types;bundle-version="[3.1.0,4.0.0)"
@@ -40,7 +39,7 @@ Export-Package: org.eclipse.papyrus.uml.diagram.clazz.test,
org.eclipse.papyrus.uml.diagram.clazz.tests.generation
Bundle-Vendor: %providerName
Bundle-ActivationPolicy: lazy
-Bundle-Version: 1.3.0.qualifier
+Bundle-Version: 1.3.100.qualifier
Bundle-Name: %pluginName
Bundle-Localization: plugin
Bundle-ManifestVersion: 2
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/pom.xml b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/pom.xml
index 6873b4ffcae..61be2acf541 100644
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/pom.xml
+++ b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/pom.xml
@@ -10,7 +10,7 @@
</parent>
<groupId>org.eclipse.papyrus.tests</groupId>
<artifactId>org.eclipse.papyrus.uml.diagram.clazz.tests</artifactId>
- <version>1.3.0-SNAPSHOT</version>
+ <version>1.3.100-SNAPSHOT</version>
<packaging>eclipse-test-plugin</packaging>
<properties>
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test-gen/.gitignore b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test-gen/.gitignore
deleted file mode 100644
index d6b7ef32c84..00000000000
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test-gen/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*
-!.gitignore
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/ClassDiagramGenerateTestsWorkflow.xtend b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/ClassDiagramGenerateTestsWorkflow.xtend
deleted file mode 100644
index a6940b3e41e..00000000000
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/ClassDiagramGenerateTestsWorkflow.xtend
+++ /dev/null
@@ -1,103 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 CEA LIST, Christian W. Damus, 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:
- * CEA LIST - Initial API and implementation
- * Christian W. Damus - bug 464647
- *
- ******************************************************************************/
-package org.eclipse.papyrus.uml.diagram.clazz.tests.generation
-
-import org.eclipse.emf.mwe2.runtime.workflow.WorkflowContextImpl
-import org.eclipse.papyrus.tests.framework.gmfgenuml2utp.GMFGen2UTPModule
-import org.eclipse.papyrus.tests.framework.mwe.GenerateTestsWorkflow
-import org.eclipse.papyrus.tests.framework.gmfgenuml2utp.CreateFromPaletteTest
-
-/**
- * Xtend program for generation of the Class Diagram tests.
- */
-class ClassDiagramGenerateTestsWorkflow {
-
- def static void main(String[] args) {
- val workflow = new GenerateTestsWorkflow()
- runWorkflow(workflow);
- }
-
- def static void runWorkflow(extension GenerateTestsWorkflow workflow) {
- testProjectName = 'org.eclipse.papyrus.uml.diagram.clazz.tests'
- gmfgenUri = resourceURI('/org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen')
-
- testSrcGenLocation = 'test-gen/'
- testModel = 'model/ClassDiagramTest.uml'
-
- utpModuleFunction = [gmfgen, framework, utp |
- new GMFGen2UTPModule(gmfgen, framework, utp) {
- override protected void bindTestRules() {
- // Inject our custom test transformation rules
- bind(CreateFromPaletteTest).to(CustomCreateFromPaletteTest)
- }
- } => [
- diagramTestPackageName = 'org.eclipse.papyrus.uml.diagram.clazz.test'
- diagramUpdater = 'CustomUMLDiagramUpdater'
- topContainerEditPart = 'PackageEditPart'
- ]
- ]
-
- except [
- editPart [
- reason = 'Most tests aren\'t applicable.'
- editPart = named('AssociationNodeEditPart') || 'DependencyNodeEditPart'
- || 'AssociationBranchEditPart' || 'DependencyBranchEditPart'
- ]
- editPart [
- reason = 'Template bindings need their targets already to have template signatures.'
- editPart = named('TemplateBindingEditPart')
- ]
- editPart [
- reason = 'Not a conventional UML presentation.'
- editPart = named('DefaultNamedElementEditPart')
- ]
- editPart [
- critical
- reason = 'Cannot generate tests for non-UML elements.'
- editPart = named('ShortCutDiagramEditPart')
- ]
- permutation [
- kind = failing
- reason = 'Classifiers should be supported as package import sources.'
- testContexts = #[ createLink, synchronization ]
- editParts [
- link += named('PackageImportEditPart')
- source += !(named('PackageEditPart') || 'ModelEditPartTN' || 'PackageEditPartCN' || 'ModelEditPartCN')
- target += any
- ]
- ]
- permutation [
- reason = 'Assocation class links only make sense from association classes to other classifiers.'
- testContexts = #[ createLink, synchronization ]
- editParts [
- // Match an association-class link either
- // - from something not an association-class to anything else, or
- // - from anything to an association-class
- link += named('AssociationClassLinkEditPart')
- linkEnds [
- source += !named('AssociationClassEditPart')
- target += named('AssociationClassEditPart')
- ]
- ]
- ]
- editPart [
- kind = failing
- reason = 'Association Class editing is broken.'
- editPart = named('AssociationClassEditPart')
- ]
- ]
-
- run(new WorkflowContextImpl);
- }
-
-}
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/CustomCreateFromPaletteTest.xtend b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/CustomCreateFromPaletteTest.xtend
deleted file mode 100644
index 78cf7e4b9ea..00000000000
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/test/org/eclipse/papyrus/uml/diagram/clazz/tests/generation/CustomCreateFromPaletteTest.xtend
+++ /dev/null
@@ -1,49 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2015 Christian W. Damus 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:
- * Christian W. Damus - Initial API and implementation
- *
- *****************************************************************************/
-
-package org.eclipse.papyrus.uml.diagram.clazz.tests.generation
-
-import javax.inject.Inject
-import javax.inject.Singleton
-import org.eclipse.papyrus.tests.framework.gmfgenuml2utp.CreateFromPaletteTest
-import org.eclipse.papyrus.tests.framework.gmfgenuml2utp.TransformationUtilities
-import org.eclipse.uml2.uml.CallOperationAction
-import org.eclipse.uml2.uml.InstanceSpecification
-
-/**
- * Customization of the create-from-palette test UTP transformation for class diagrams, to
- * account for specific custom editing behaviours of this diagram.
- */
- @Singleton
-class CustomCreateFromPaletteTest extends CreateFromPaletteTest {
- @Inject extension TransformationUtilities
- final String defaultAssociationName = 'srcMul'
-
- override protected def toCallTestLinkOperationActivity(InstanceSpecification linkEditPart, InstanceSpecification sourceEditPart, InstanceSpecification targetEditPart) {
- super.toCallTestLinkOperationActivity(linkEditPart, sourceEditPart, targetEditPart) => [
- if (linkEditPart.editPart == 'AssociationEditPart') {
- // Insert a parameter for the association name (invokes a different overloaded variant of the framework method)
- ownedNodes.filter(CallOperationAction).head.arguments.add(3, defaultAssociationName.toValuePin('initialName'))
- }
- ]
- }
-
- override protected def toCallTestLinkOperationActivity(InstanceSpecification linkEditPart, InstanceSpecification sourceEditPart, InstanceSpecification targetEditPart, InstanceSpecification containerEditPart) {
- super.toCallTestLinkOperationActivity(linkEditPart, sourceEditPart, targetEditPart, containerEditPart) => [
- if (linkEditPart.editPart == 'AssociationEditPart') {
- // Insert a parameter for the association name (invokes a different overloaded variant of the framework method)
- ownedNodes.filter(CallOperationAction).head.arguments.add(4, defaultAssociationName.toValuePin('initialName'))
- }
- ]
- }
-}
diff --git a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/xtend-gen/.gitignore b/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/xtend-gen/.gitignore
deleted file mode 100644
index d6b7ef32c84..00000000000
--- a/tests/junit/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.clazz.tests/xtend-gen/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*
-!.gitignore

Back to the top