From 2f0cd462efa173919740c9b220ae1d40538a8ac3 Mon Sep 17 00:00:00 2001 From: rschnekenbu Date: Thu, 24 May 2012 16:54:42 +0000 Subject: 374636: [SYSML][Model Explorer] Copy / paste of a part does not create the corresponding association https://bugs.eclipse.org/bugs/show_bug.cgi?id=374636 --- .../model/ModelWithBDD.di | 6 + .../model/ModelWithBDD.notation | 586 +++++++++++---------- .../model/ModelWithBDD.uml | 10 + .../model/SysMLModelExplorerCopyPasteTestModel.di | 6 + .../SysMLModelExplorerCopyPasteTestModel.notation | 54 ++ .../model/SysMLModelExplorerCopyPasteTestModel.uml | 41 +- .../copypaste/AbstractCopyPasteBlockTest.java | 69 +-- .../copypaste/AbstractCopyPasteReferenceTest.java | 70 +++ .../tests/copypaste/AbstractCopyPasteTest.java | 6 +- .../copypaste/CopyPasteSimpleReferenceTest.java | 137 +++++ .../tests/suites/AllCopyPasteTests.java | 6 +- 11 files changed, 638 insertions(+), 353 deletions(-) create mode 100644 tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteReferenceTest.java create mode 100644 tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/CopyPasteSimpleReferenceTest.java (limited to 'tests') diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.di b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.di index 3b41d552d1e..49f96c92a31 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.di +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.di @@ -4,6 +4,9 @@ + + + @@ -11,6 +14,9 @@ + + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.notation b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.notation index 7a409986aa4..4bd308bc881 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.notation +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.notation @@ -1,291 +1,319 @@ - - - -
- - -
- - -
- - - - - - - + + + + +
+ + +
+ + +
+ + + + + + + + + + + + + + + + + + + + + + - - - - + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - -
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - + + +
+ + +
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - -
- - -
- - -
- - - - - -
- - -
- - -
- - - - - - - + + +
+ + +
+ + +
+ + + + + +
+ + +
+ + +
+ + + + + + + + + + + + + + + + + - - - - + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - + + +
+ + +
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + - - -
- - -
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + +
+ + +
+ + +
+ + + + - - + + - - - - - - + + + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.uml b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.uml index 66c3b3cfd98..3d1e2bd1862 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.uml +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/ModelWithBDD.uml @@ -10,6 +10,10 @@ + + + + @@ -49,6 +53,12 @@ + + +
+ + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.di b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.di index 4dad1416737..86d19ca6083 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.di +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.di @@ -10,6 +10,9 @@ + + + @@ -23,6 +26,9 @@ + + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.notation b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.notation index b15584e1a7e..81df318b390 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.notation +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.notation @@ -63,6 +63,24 @@ + + +
+ + +
+ + +
+ + + + + + + + + @@ -197,4 +215,40 @@ + + + +
+ + +
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.uml b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.uml index 58de843122d..9096891dc4a 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.uml +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/model/SysMLModelExplorerCopyPasteTestModel.uml @@ -7,6 +7,9 @@ + + + @@ -32,35 +35,7 @@ - + @@ -71,4 +46,12 @@ + + + + + + + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteBlockTest.java b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteBlockTest.java index 2028a57fa18..f542dd48ec3 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteBlockTest.java +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteBlockTest.java @@ -18,11 +18,20 @@ import java.util.ArrayList; import java.util.List; import java.util.Map; -import org.eclipse.emf.ecore.EObject; import org.eclipse.papyrus.core.utils.FilteredCollectionView; import org.eclipse.papyrus.core.utils.IFilter; +import org.eclipse.core.commands.ExecutionEvent; +import org.eclipse.core.runtime.NullProgressMonitor; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.ui.IWorkbenchCommandConstants; +import org.eclipse.ui.PlatformUI; +import org.eclipse.ui.commands.ICommandService; +import org.eclipse.uml2.uml.Association; import org.eclipse.uml2.uml.Property; +import org.eclipse.uml2.uml.UMLPackage; import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; /** @@ -31,55 +40,31 @@ import org.junit.Assert; public abstract class AbstractCopyPasteBlockTest extends AbstractCopyPasteTest { /** - * {@inheritDoc} - * - * @generated - */ + * {@inheritDoc} + * @generated + */ @Override protected void initializeTest(Map additionalChecks, EObject targetContainer, EObject copiedEObject) { - super.initializeTest(additionalChecks, targetContainer, copiedEObject); - - /* pre-copy initialization */ - List originalParts = new ArrayList(); - for(Property p : ((org.eclipse.uml2.uml.Class)copiedEObject).getAllAttributes()) { - if(new org.eclipse.papyrus.sysml.service.types.matcher.PartPropertyMatcher().matches(p)) { - originalParts.add(p); - } - } - additionalChecks.put("originalParts", originalParts); - /* END OF pre-copy initialization */ - } + super.initializeTest(additionalChecks, targetContainer, copiedEObject); + + /* pre-copy initialization */ + List originalParts = new ArrayList(); for(Property p : ((org.eclipse.uml2.uml.Class)copiedEObject).getAllAttributes()) { if(new org.eclipse.papyrus.sysml.service.types.matcher.PartPropertyMatcher().matches(p)) {originalParts.add(p);}} additionalChecks.put("originalParts", originalParts); + /* END OF pre-copy initialization */ + } /** * {@inheritDoc} - * - * @generated + * @generated */ @Override protected void postCopyAdditionalChecks(Map originalModel, List newValues, List delta) throws Exception { - super.postCopyAdditionalChecks(originalModel, newValues, delta); + super.postCopyAdditionalChecks(originalModel, newValues, delta); + + /* post copy checks */ + FilteredCollectionView newClasses = new FilteredCollectionView(delta, new IFilter() { /** * {@inheritDoc} */ public boolean isAllowed(Object object) { return object instanceof org.eclipse.uml2.uml.Class && !(object instanceof org.eclipse.uml2.uml.Association); } }); Assert.assertEquals("New values should contain a Class", 1, newClasses.size()); org.eclipse.uml2.uml.Class newBlock = newClasses.toArray(new org.eclipse.uml2.uml.Class[]{})[0]; Assert.assertNotNull("Block stereotype should be applied", ((org.eclipse.uml2.uml.Class) newBlock) .getAppliedStereotype("SysML::Blocks::Block")); List originalParts = (List) originalModel .get("originalParts"); List newParts = new ArrayList(); for (Property p : ((org.eclipse.uml2.uml.Class) newBlock) .getAllAttributes()) { if (new org.eclipse.papyrus.sysml.service.types.matcher.PartPropertyMatcher().matches(p)) { newParts.add(p); Assert.assertNotNull( "Part should have an associated association.", p.getAssociation()); } } Assert.assertEquals( "Both original and new list of attributes should be quivalent for the blocks", originalParts.size(), newParts.size()); + /* END OF post copy checks */ + } - /* post copy checks */ - FilteredCollectionView newClasses = new FilteredCollectionView(delta, new IFilter() { +} - /** * {@inheritDoc} */ - public boolean isAllowed(Object object) { - return object instanceof org.eclipse.uml2.uml.Class && !(object instanceof org.eclipse.uml2.uml.Association); - } - }); - Assert.assertEquals("New values should contain a Class", 1, newClasses.size()); - org.eclipse.uml2.uml.Class newBlock = newClasses.toArray(new org.eclipse.uml2.uml.Class[]{})[0]; - Assert.assertNotNull("Block stereotype should be applied", ((org.eclipse.uml2.uml.Class)newBlock).getAppliedStereotype("SysML::Blocks::Block")); - List originalParts = (List)originalModel.get("originalParts"); - List newParts = new ArrayList(); - for(Property p : ((org.eclipse.uml2.uml.Class)newBlock).getAllAttributes()) { - if(new org.eclipse.papyrus.sysml.service.types.matcher.PartPropertyMatcher().matches(p)) { - newParts.add(p); - Assert.assertNotNull("Part should have an associated association.", p.getAssociation()); - } - } - Assert.assertEquals("Both original and new list of attributes should be quivalent for the blocks", originalParts.size(), newParts.size()); - /* END OF post copy checks */ - } -} diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteReferenceTest.java b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteReferenceTest.java new file mode 100644 index 00000000000..66749495225 --- /dev/null +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteReferenceTest.java @@ -0,0 +1,70 @@ +/***************************************************************************** + * Copyright (c) 2011 CEA LIST. + * + * 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: + * Remi Schnekenburger (CEA LIST) remi.schnekenburger@cea.fr - Initial API and implementation + * + * @Generated from Reference - Model + * + *****************************************************************************/ +package org.eclipse.papyrus.sysml.modelexplorer.tests.copypaste; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import org.eclipse.papyrus.core.utils.FilteredCollectionView; +import org.eclipse.papyrus.core.utils.IFilter; +import org.eclipse.core.commands.ExecutionEvent; +import org.eclipse.core.runtime.NullProgressMonitor; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.ui.IWorkbenchCommandConstants; +import org.eclipse.ui.PlatformUI; +import org.eclipse.ui.commands.ICommandService; +import org.eclipse.uml2.uml.Association; +import org.eclipse.uml2.uml.Property; +import org.eclipse.uml2.uml.UMLPackage; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; + + +/** + * Test for Copy / Paste of a Part + */ +public abstract class AbstractCopyPasteReferenceTest extends AbstractCopyPasteTest { + + /** + * {@inheritDoc} + * @generated + */ + @Override + protected void initializeTest(Map additionalChecks, EObject targetContainer, EObject copiedEObject) { + super.initializeTest(additionalChecks, targetContainer, copiedEObject); + + /* pre-copy initialization */ + + /* END OF pre-copy initialization */ + } + + /** + * {@inheritDoc} + * @generated + */ + @Override + protected void postCopyAdditionalChecks(Map originalModel, List newValues, List delta) throws Exception { + super.postCopyAdditionalChecks(originalModel, newValues, delta); + + /* post copy checks */ + Association newAssociation = ((Property)newValues.get(0)).getAssociation(); Assert.assertNotNull("New Reference should have an association", newAssociation); + /* END OF post copy checks */ + } + +} + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteTest.java b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteTest.java index 650bf161fde..aff4709e54b 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteTest.java +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/AbstractCopyPasteTest.java @@ -76,6 +76,7 @@ public abstract class AbstractCopyPasteTest { protected static org.eclipse.uml2.uml.Model model_EObject; protected static org.eclipse.uml2.uml.Class b1_EObject; protected static org.eclipse.uml2.uml.Property pB2_B1_EObject; + protected static org.eclipse.uml2.uml.Property rB2_B1_EObject; protected static org.eclipse.uml2.uml.Property pB1P1_B1_EObject; protected static org.eclipse.uml2.uml.Class b2_EObject; @@ -101,6 +102,7 @@ public abstract class AbstractCopyPasteTest { + /** end of generated selectable objects */ @@ -121,6 +123,7 @@ public abstract class AbstractCopyPasteTest { model_EObject = (org.eclipse.uml2.uml.Model)root; b1_EObject = (org.eclipse.uml2.uml.Class) model_EObject.getPackagedElement("B1"); pB2_B1_EObject = (org.eclipse.uml2.uml.Property) b1_EObject.getAttribute("pB2", null); + rB2_B1_EObject = (org.eclipse.uml2.uml.Property) b1_EObject.getAttribute("rB2", null); pB1P1_B1_EObject = (org.eclipse.uml2.uml.Property) b1_EObject.getAttribute("pB1P1", null); b2_EObject = (org.eclipse.uml2.uml.Class) model_EObject.getPackagedElement("B2"); @@ -146,6 +149,7 @@ public abstract class AbstractCopyPasteTest { + /** end of generated selectable objects */ } @@ -162,7 +166,7 @@ public abstract class AbstractCopyPasteTest { IIntroPart introPart = PlatformUI.getWorkbench().getIntroManager().getIntro(); PlatformUI.getWorkbench().getIntroManager().closeIntro(introPart); // Prepare new project for tests - IProject testProject = ResourcesPlugin.getWorkspace().getRoot().getProject("TestProject"); + IProject testProject = ResourcesPlugin.getWorkspace().getRoot().getProject("TestCopyPasteProject"); if(!testProject.exists()) { testProject.create(new NullProgressMonitor()); } diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/CopyPasteSimpleReferenceTest.java b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/CopyPasteSimpleReferenceTest.java new file mode 100644 index 00000000000..abfab4650f0 --- /dev/null +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/copypaste/CopyPasteSimpleReferenceTest.java @@ -0,0 +1,137 @@ +/***************************************************************************** + * Copyright (c) 2011 CEA LIST. + * + * 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: + * Remi Schnekenburger (CEA LIST) remi.schnekenburger@cea.fr - Initial API and implementation + * + * @Generated from SimpleReference - Model + * + *****************************************************************************/ +package org.eclipse.papyrus.sysml.modelexplorer.tests.copypaste; + +import java.util.List; +import java.util.Map; + +import org.eclipse.core.commands.ExecutionEvent; +import org.eclipse.core.runtime.NullProgressMonitor; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.ui.IWorkbenchCommandConstants; +import org.eclipse.ui.PlatformUI; +import org.eclipse.ui.commands.ICommandService; +import org.eclipse.uml2.uml.Association; +import org.eclipse.uml2.uml.Property; +import org.eclipse.uml2.uml.UMLPackage; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; + + +/** + * Test for Copy / Paste of a Part + */ +public class CopyPasteSimpleReferenceTest extends AbstractCopyPasteReferenceTest { + + /** + * prepare the copy + * + * @throws Exception + * exception thrown in case of problems + */ + @Before + public void testPrepare() throws Exception { + // check editor state (should be non dirty) + Assert.assertFalse("Editor should not be dirty at initialization", isEditorDirty()); + // retrieve elements in the model explorer + selectAndReveal( rB2_B1_EObject); + + // copy Paste + ICommandService commandService = (ICommandService)PlatformUI.getWorkbench().getService(ICommandService.class); + commandService.refreshElements(IWorkbenchCommandConstants.EDIT_COPY, null); + org.eclipse.core.commands.Command copyCommand = commandService.getCommand(IWorkbenchCommandConstants.EDIT_COPY); + Assert.assertNotNull("Impossible to find copy command", copyCommand); + Assert.assertTrue("command in not enabled", copyCommand.isEnabled()); + Assert.assertTrue("command in not defined", copyCommand.isDefined()); + copyCommand.executeWithChecks(new ExecutionEvent()); + + // check editor state (should be non dirty) + // Assert.assertFalse("Editor should not be dirty after copy", isEditorDirty()); + + // NOTE: save editor. The copy command should not dirty the model, the implementation of the copy command or the editor should be modified + Assert.assertTrue("Copy command is dirtying the model, whereas it should not. This assert is here to remember that the test code should be modified: Isdirty = false after copy...", isEditorDirty()); + PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor().doSave(new NullProgressMonitor()); + Assert.assertFalse("Save command is non-dirtying the model, whereas it should. ", isEditorDirty()); + // END NOTE + } + + @Override + protected void initializeTest(Map additionalChecks, EObject targetContainer, EObject copiedEObject) { + super.initializeTest(additionalChecks, targetContainer, copiedEObject); + + /* pre-copy initialization */ + + /* END OF pre-copy initialization */ + } + + /** + * {@inheritDoc} + */ + @Override + protected void postCopyAdditionalChecks(Map originalModel, List newValues, List delta) throws Exception { + super.postCopyAdditionalChecks(originalModel, newValues, delta); + + /* post copy checks */ + + /* END OF post copy checks */ + } + + + /** + * Test the copy /paste on B1 + * + * @throws Exception + * exception thrown in case of problems + */ + @Test + public void testCopyPasteInB1() throws Exception { + testExecutableCopyPaste( b1_EObject, rB2_B1_EObject, "attribute", 1); + } + /** + * Test the copy /paste on B2 + * + * @throws Exception + * exception thrown in case of problems + */ + @Test + public void testCopyPasteInB2() throws Exception { + testExecutableCopyPaste( b2_EObject, rB2_B1_EObject, "attribute", 1); + } + /** + * Test the copy /paste on B1P1 + * + * @throws Exception + * exception thrown in case of problems + */ + @Test + public void testCopyPasteInB1P1() throws Exception { + testExecutableCopyPaste( b1P1_P1_EObject, rB2_B1_EObject, "attribute", 1); + } + /** + * Test the copy /paste on B2P1 + * + * @throws Exception + * exception thrown in case of problems + */ + @Test + public void testCopyPasteInB2P1() throws Exception { + testExecutableCopyPaste( b2P1_P1_EObject, rB2_B1_EObject, "attribute", 1); + } + + +} + + diff --git a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/suites/AllCopyPasteTests.java b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/suites/AllCopyPasteTests.java index c53f0dbcce0..eac94a048e1 100644 --- a/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/suites/AllCopyPasteTests.java +++ b/tests/junit/plugins/sysml/org.eclipse.papyrus.sysml.modelexplorer.tests/test-gen/org/eclipse/papyrus/sysml/modelexplorer/tests/suites/AllCopyPasteTests.java @@ -24,11 +24,13 @@ import org.junit.runners.Suite.SuiteClasses; */ @RunWith(Suite.class) @SuiteClasses({ +// Part +CopyPasteSimplePartTest.class, // Block CopyPasteSimpleBlock2Test.class, CopyPasteSimpleBlockTest.class, -// Part -CopyPasteSimplePartTest.class, +// Reference +CopyPasteSimpleReferenceTest.class, }) public class AllCopyPasteTests { -- cgit v1.2.3