Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas FAUVERGUE2015-11-27 12:30:56 +0000
committervincent lorenzo2016-01-08 16:05:25 +0000
commit5a8347c6a3bceb39103ea0362085c9426c3c4b7e (patch)
tree437ae5700648ad1bec1e26be345d8958a300c650
parent75831599d5aa8d3f8613671632145451df800df2 (diff)
downloadorg.eclipse.papyrus-5a8347c6a3bceb39103ea0362085c9426c3c4b7e.tar.gz
org.eclipse.papyrus-5a8347c6a3bceb39103ea0362085c9426c3c4b7e.tar.xz
org.eclipse.papyrus-5a8347c6a3bceb39103ea0362085c9426c3c4b7e.zip
Bug 467706: [Table 2] Tree Table with no tree filling configuration on
depth==0 can't be reopened https://bugs.eclipse.org/bugs/show_bug.cgi?id=467706 JUnit tests for this bug. Change-Id: Id19207ee70d9a2869119eb4a596867376562963c Signed-off-by: Nicolas FAUVERGUE <nicolas.fauvergue@all4tec.net>
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.di2
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.notation55
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.uml4
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/bugs/NoDepth0TreeFillingConfigurationTest.java188
-rw-r--r--tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/tests/AllTests.java2
5 files changed, 251 insertions, 0 deletions
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.di b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.di
new file mode 100644
index 00000000000..bf9abab340f
--- /dev/null
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.di
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xmi:XMI xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI"/>
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.notation b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.notation
new file mode 100644
index 00000000000..7cc9e6bec2c
--- /dev/null
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.notation
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<nattable:Table xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:configuration="http://www.eclipse.org/papyrus/infra/viewpoints/configuration" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:nattable="http://www.eclipse.org/papyrus/nattable/model" xmlns:nattableaxis="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxis" xmlns:nattableaxisconfiguration="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisconfiguration" xmlns:nattableaxisprovider="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisprovider" xmlns:nattableconfiguration="http://www.eclipse.org/papyrus/nattable/model/nattableconfiguration" xmlns:nattablelabelprovider="http://www.eclipse.org/papyrus/nattable/model/table/nattablecontentprovider" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xsi:schemaLocation="http://www.eclipse.org/papyrus/nattable/model/table/nattableaxis http://www.eclipse.org/papyrus/nattable/model#//nattableaxis http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisconfiguration http://www.eclipse.org/papyrus/nattable/model#//nattableaxisconfiguration http://www.eclipse.org/papyrus/nattable/model/table/nattableaxisprovider http://www.eclipse.org/papyrus/nattable/model#//nattableaxisprovider http://www.eclipse.org/papyrus/nattable/model/nattableconfiguration http://www.eclipse.org/papyrus/nattable/model#//nattableconfiguration http://www.eclipse.org/papyrus/nattable/model/table/nattablecontentprovider http://www.eclipse.org/papyrus/nattable/model#//nattablelabelprovider" xmi:id="_3kVVsJTcEeWwmpQpJqo7nw" name="ClassTreeTable" currentRowAxisProvider="_3kV8wpTcEeWwmpQpJqo7nw" currentColumnAxisProvider="_3kV8wJTcEeWwmpQpJqo7nw">
+ <context xmi:type="uml:Model" href="NoDepth0TreeFillingConfigurationTest.uml#_aDGFYJTcEeWwmpQpJqo7nw"/>
+ <owner xmi:type="uml:Model" href="NoDepth0TreeFillingConfigurationTest.uml#_aDGFYJTcEeWwmpQpJqo7nw"/>
+ <prototype xmi:type="configuration:PapyrusSyncTable" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/classTreeTable.configuration#_P3J1cEr7EeSVGbM3cmVSqQ"/>
+ <tableConfiguration xmi:type="nattableconfiguration:TableConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#/"/>
+ <columnAxisProvidersHistory xmi:type="nattableaxisprovider:SlaveObjectAxisProvider" xmi:id="_3kV8wJTcEeWwmpQpJqo7nw" description="This axis provider provides available columns according to the rows of the table (features of the object displayed on the other axis)" name="UML Feature axis provider">
+ <axis xmi:type="nattableaxis:EStructuralFeatureAxis" xmi:id="_3kV8wZTcEeWwmpQpJqo7nw">
+ <manager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@columnHeaderAxisConfiguration/@axisManagers.0"/>
+ <element xmi:type="ecore:EAttribute" href="http://www.eclipse.org/uml2/5.0.0/UML#//NamedElement/name"/>
+ </axis>
+ </columnAxisProvidersHistory>
+ <rowAxisProvidersHistory xmi:type="nattableaxisprovider:MasterObjectAxisProvider" xmi:id="_3kV8wpTcEeWwmpQpJqo7nw" description="This axis provider manages the rows, according to the wanted hierarchy" name="HierarchicalRowaAxisManager" disconnectSlave="true"/>
+ <localRowHeaderAxisConfiguration xmi:type="nattableaxisconfiguration:LocalTableHeaderAxisConfiguration" xmi:id="_5Vw3EJTcEeWwmpQpJqo7nw" indexStyle="NUMERIC">
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:TreeFillingConfiguration" xmi:id="_5Vz6YJTcEeWwmpQpJqo7nw" pasteConfiguration="_5V0hcJTcEeWwmpQpJqo7nw" depth="1" labelProviderContext="org.eclipse.papyrus.infra.nattable.header.treefilling.feature.labelprovider">
+ <axisUsedAsAxisProvider xmi:type="nattableaxis:EStructuralFeatureAxis" xmi:id="_5Vz6YZTcEeWwmpQpJqo7nw" alias="">
+ <element xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//StructuredClassifier/ownedAttribute"/>
+ </axisUsedAsAxisProvider>
+ <labelProvider xmi:type="nattablelabelprovider:FeatureLabelProviderConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@rowHeaderAxisConfiguration/@ownedLabelConfigurations.1"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:TreeFillingConfiguration" xmi:id="_5Vz6YpTcEeWwmpQpJqo7nw" pasteConfiguration="_5V0hcZTcEeWwmpQpJqo7nw" depth="1" labelProviderContext="org.eclipse.papyrus.infra.nattable.header.treefilling.feature.labelprovider">
+ <axisUsedAsAxisProvider xmi:type="nattableaxis:EStructuralFeatureAxis" xmi:id="_5Vz6Y5TcEeWwmpQpJqo7nw" alias="">
+ <element xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class/nestedClassifier"/>
+ </axisUsedAsAxisProvider>
+ <labelProvider xmi:type="nattablelabelprovider:FeatureLabelProviderConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@rowHeaderAxisConfiguration/@ownedLabelConfigurations.1"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:TreeFillingConfiguration" xmi:id="_5Vz6ZJTcEeWwmpQpJqo7nw" pasteConfiguration="_5V0hcpTcEeWwmpQpJqo7nw" depth="1" labelProviderContext="org.eclipse.papyrus.infra.nattable.header.treefilling.feature.labelprovider">
+ <axisUsedAsAxisProvider xmi:type="nattableaxis:EStructuralFeatureAxis" xmi:id="_5Vz6ZZTcEeWwmpQpJqo7nw" alias="">
+ <element xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class/ownedOperation"/>
+ </axisUsedAsAxisProvider>
+ <labelProvider xmi:type="nattablelabelprovider:FeatureLabelProviderConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@rowHeaderAxisConfiguration/@ownedLabelConfigurations.1"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:TreeFillingConfiguration" xmi:id="_5Vz6ZpTcEeWwmpQpJqo7nw" pasteConfiguration="_5V0hc5TcEeWwmpQpJqo7nw" depth="2" labelProviderContext="org.eclipse.papyrus.infra.nattable.header.treefilling.feature.labelprovider">
+ <axisUsedAsAxisProvider xmi:type="nattableaxis:EStructuralFeatureAxis" xmi:id="_5Vz6Z5TcEeWwmpQpJqo7nw" alias="">
+ <element xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//BehavioralFeature/ownedParameter"/>
+ </axisUsedAsAxisProvider>
+ <labelProvider xmi:type="nattablelabelprovider:FeatureLabelProviderConfiguration" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@rowHeaderAxisConfiguration/@ownedLabelConfigurations.1"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:PasteEObjectConfiguration" xmi:id="_5V0hcJTcEeWwmpQpJqo7nw" pastedElementId="org.eclipse.papyrus.uml.Property">
+ <pasteElementContainementFeature xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//StructuredClassifier/ownedAttribute"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:PasteEObjectConfiguration" xmi:id="_5V0hcZTcEeWwmpQpJqo7nw" pastedElementId="org.eclipse.papyrus.uml.Class">
+ <pasteElementContainementFeature xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class/nestedClassifier"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:PasteEObjectConfiguration" xmi:id="_5V0hcpTcEeWwmpQpJqo7nw" pastedElementId="org.eclipse.papyrus.uml.Operation">
+ <pasteElementContainementFeature xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//Class/ownedOperation"/>
+ </ownedAxisConfigurations>
+ <ownedAxisConfigurations xmi:type="nattableaxisconfiguration:PasteEObjectConfiguration" xmi:id="_5V0hc5TcEeWwmpQpJqo7nw" pastedElementId="org.eclipse.papyrus.uml.Parameter">
+ <pasteElementContainementFeature xmi:type="ecore:EReference" href="http://www.eclipse.org/uml2/5.0.0/UML#//BehavioralFeature/ownedParameter"/>
+ </ownedAxisConfigurations>
+ <axisManagerConfigurations xmi:type="nattableaxisconfiguration:AxisManagerConfiguration" xmi:id="_5VzTUJTcEeWwmpQpJqo7nw" localSpecificConfigurations="_5Vz6YJTcEeWwmpQpJqo7nw _5Vz6YpTcEeWwmpQpJqo7nw _5Vz6ZJTcEeWwmpQpJqo7nw _5Vz6ZpTcEeWwmpQpJqo7nw">
+ <axisManager xmi:type="nattableaxisconfiguration:AxisManagerRepresentation" href="platform:/plugin/org.eclipse.papyrus.uml.nattable.clazz.config/configs/class_synchronized_tree.nattableconfiguration#//@rowHeaderAxisConfiguration/@axisManagers.0"/>
+ </axisManagerConfigurations>
+ </localRowHeaderAxisConfiguration>
+</nattable:Table>
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.uml b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.uml
new file mode 100644
index 00000000000..464ff4d2c56
--- /dev/null
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.uml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<uml:Model xmi:version="20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML" xmi:id="_aDGFYJTcEeWwmpQpJqo7nw" name="RootElement">
+ <packagedElement xmi:type="uml:Class" xmi:id="_GqMPoJTfEeWx9KtEop_Tug" name="Class1"/>
+</uml:Model>
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/bugs/NoDepth0TreeFillingConfigurationTest.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/bugs/NoDepth0TreeFillingConfigurationTest.java
new file mode 100644
index 00000000000..bf3d81965b9
--- /dev/null
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/bugs/NoDepth0TreeFillingConfigurationTest.java
@@ -0,0 +1,188 @@
+/*****************************************************************************
+ * Copyright (c) 2015 CEA LIST 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:
+ * Nicolas FAUVERGUE (ALL4TEC) nicolas.fauvergue@all4tec.net - Initial API and implementation
+ *
+ *****************************************************************************/
+
+package org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.emf.common.command.Command;
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.transaction.TransactionalEditingDomain;
+import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IPageManager;
+import org.eclipse.papyrus.infra.nattable.common.editor.NatTableEditor;
+import org.eclipse.papyrus.infra.nattable.manager.table.INattableModelManager;
+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.junit.framework.classification.tests.AbstractPapyrusTest;
+import org.eclipse.papyrus.junit.utils.TableUtils;
+import org.eclipse.papyrus.junit.utils.rules.PapyrusEditorFixture;
+import org.eclipse.papyrus.junit.utils.rules.PluginResource;
+import org.eclipse.papyrus.views.modelexplorer.ModelExplorerView;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IViewPart;
+import org.eclipse.uml2.uml.Model;
+import org.eclipse.uml2.uml.UMLPackage;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.Test;
+
+/**
+ * This allows to manage the bug 467706 (No Tree filling configuration for depth 0, add object and close then reopen it).
+ */
+@PluginResource("resources/bugs/bug467706/NoDepth0TreeFillingConfigurationTest.di") //$NON-NLS-1$
+public class NoDepth0TreeFillingConfigurationTest extends AbstractPapyrusTest {
+
+ /**
+ * The first class name in the model.
+ */
+ private static final String FIRST_CLASS = "Class1"; //$NON-NLS-1$
+
+ /**
+ * The table name.
+ */
+ private static final String TABLE_NAME = "ClassTreeTable"; //$NON-NLS-1$
+
+ /**
+ * The papyrus fixture.
+ */
+ @Rule
+ public final PapyrusEditorFixture fixture = new PapyrusEditorFixture();
+
+ /**
+ * The current model.
+ */
+ public Model model = null;
+
+ /**
+ * The model explorer part.
+ */
+ public IViewPart modelExplorerPart = null;
+
+ /**
+ * The model explorer view.
+ */
+ public ModelExplorerView modelExplorerView = null;
+
+ /**
+ * The nattable model manager.
+ */
+ public INattableModelManager currentManager = null;
+
+ /**
+ * Constructor.
+ */
+ public NoDepth0TreeFillingConfigurationTest() {
+ super();
+ }
+
+ /**
+ * Initialize.
+ */
+ @Before
+ public void init() {
+ // Get the model
+ model = (Model) fixture.getModel();
+ Assert.assertNotNull("RootModel is null", model); //$NON-NLS-1$
+
+ // Get the table and open it
+ final Table mainTable = TableUtils.getNotationFirstTable(fixture.getModelSet(), TABLE_NAME);
+ fixture.getPageManager().openPage(mainTable);
+ fixture.flushDisplayEvents();
+
+ // Get the table and its manager
+ final IPageManager pageManager = fixture.getPageManager();
+ final List<Object> pages = pageManager.allPages();
+ pageManager.openPage(pages.get(0));
+ final IEditorPart part = fixture.getEditor().getActiveEditor();
+ Assert.assertTrue(part instanceof NatTableEditor);
+ final NatTableEditor editor = (NatTableEditor) part;
+ currentManager = (INattableModelManager) editor.getAdapter(INattableModelManager.class);
+ Assert.assertTrue("The table manage must be a tree table manager", currentManager instanceof TreeNattableModelManager); //$NON-NLS-1$
+ }
+
+ /**
+ * This allows to test the move in the same parent.
+ *
+ * @throws Exception
+ * The exception
+ */
+ @Test
+ public void testReopenedWithoutDepth0TreefillingConfiguration() throws Exception {
+ // The table must be empty
+ Assert.assertEquals("The table must be empty", 0, currentManager.getRowElementsList().size()); // $NON-NLS-N$
+
+ // Get the editing domain
+ TransactionalEditingDomain editingDomain = fixture.getEditingDomain();
+ Assert.assertNotNull("The editing domain cannot be null", editingDomain); //$NON-NLS-1$
+
+ // Get the first class
+ final EObject firstClass = model.getPackagedElement(FIRST_CLASS);
+
+ final Collection<Object> objectsToAdd = new ArrayList<Object>(1);
+ objectsToAdd.add(firstClass);
+
+ // Add the element to the table
+ final Command addCommand = currentManager.getAddRowElementCommand(objectsToAdd);
+
+ // Execute the command
+ editingDomain.getCommandStack().execute(addCommand);
+ fixture.flushDisplayEvents();
+
+ // Save the project
+ IEditorPart part = fixture.getEditor().getActiveEditor();
+ part.doSave(new NullProgressMonitor());
+
+ // Close the table
+ final Table mainTable = TableUtils.getNotationFirstTable(fixture.getModelSet(), TABLE_NAME);
+ fixture.getPageManager().closePage(mainTable);
+ fixture.flushDisplayEvents();
+
+ // Reopen the table
+ init();
+
+ Assert.assertEquals("The table must be not empty", 1, currentManager.getRowElementsList().size()); //$NON-NLS-1$
+
+ final IAxis firstRow = (IAxis) currentManager.getRowElementsList().get(0);
+ final Object firstRowRepresentedElement = firstRow.getElement();
+ Assert.assertEquals("The first element must be a class", UMLPackage.eINSTANCE.getClass_(), ((EObject) firstRowRepresentedElement).eClass()); //$NON-NLS-1$
+ Assert.assertEquals("The name of the first element is not corresponding to the first class", FIRST_CLASS, ((org.eclipse.uml2.uml.Class) firstRowRepresentedElement).getName()); //$NON-NLS-1$
+
+ // Test the undo
+ editingDomain.getCommandStack().undo();
+ fixture.flushDisplayEvents();
+
+ // Save the project
+ part = fixture.getEditor().getActiveEditor();
+ part.doSave(new NullProgressMonitor());
+
+ // Close the table
+ fixture.getPageManager().closePage(mainTable);
+ fixture.flushDisplayEvents();
+
+ // Reopen the table
+ init();
+
+ // The table must be empty
+ Assert.assertEquals("The table must be empty", 0, currentManager.getRowElementsList().size()); // $NON-NLS-N$
+
+ // Close the table
+ fixture.getPageManager().closePage(mainTable);
+ fixture.flushDisplayEvents();
+ }
+
+} \ No newline at end of file
diff --git a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/tests/AllTests.java b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/tests/AllTests.java
index 47da0371ac3..9a3978e1fac 100644
--- a/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/tests/AllTests.java
+++ b/tests/junit/plugins/uml/nattable/org.eclipse.papyrus.uml.nattable.clazz.config.tests/src/org/eclipse/papyrus/uml/nattable/clazz/config/tests/tests/AllTests.java
@@ -20,6 +20,7 @@ import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.AxisChangeIndexW
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.DeleteRequirementsWithNestedClassifier;
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.EditInvalidPastedText_V1_V3_V1;
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.MoveElementsTreeTableTest;
+import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.NoDepth0TreeFillingConfigurationTest;
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.bugs.OpenAndDeleteTest;
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.creation.outside.CreateElementDepth0_H1_V3_V1_Test;
import org.eclipse.papyrus.uml.nattable.clazz.config.tests.creation.outside.CreateElementDepth0_V1_V3_V1_Test;
@@ -180,6 +181,7 @@ import org.junit.runners.Suite.SuiteClasses;
OpenTableTest.class,
OpenAndDeleteTest.class,
Bug_481017_ReloadEditorTest.class,
+ NoDepth0TreeFillingConfigurationTest.class,
SortAxisClassTreeTableTest.class,
EditAxisClassTreeTableTest.class,

Back to the top