Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Barbin2018-02-21 10:22:51 +0000
committerFlorian Barbin2018-03-02 08:36:05 +0000
commit3029a61d6edb5c1f0ebe4c2424e6bdc75743d367 (patch)
treef2f52e85228cd38d597f6e6475393607fd4b086f
parent0f4aa22979a33be777e5cf2576c1f8f89d0b196a (diff)
downloadorg.eclipse.sirius-3029a61d6edb5c1f0ebe4c2424e6bdc75743d367.tar.gz
org.eclipse.sirius-3029a61d6edb5c1f0ebe4c2424e6bdc75743d367.tar.xz
org.eclipse.sirius-3029a61d6edb5c1f0ebe4c2424e6bdc75743d367.zip
[497469] Adds condition in existing automatic tests
This allows to detect the regression fixed by this bugzilla. Bug: 497469 Cherry-picked-from: 530817 Change-Id: Ie453983396c96b34a6f09925d819fb0249d552d1 Signed-off-by: Florian Barbin <florian.barbin@obeo.fr>
-rw-r--r--plugins/org.eclipse.sirius.tests.swtbot/src/org/eclipse/sirius/tests/swtbot/ExportDiagramsAsImagesTest.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/org.eclipse.sirius.tests.swtbot/src/org/eclipse/sirius/tests/swtbot/ExportDiagramsAsImagesTest.java b/plugins/org.eclipse.sirius.tests.swtbot/src/org/eclipse/sirius/tests/swtbot/ExportDiagramsAsImagesTest.java
index b03b2f0f16..7f6e4adce4 100644
--- a/plugins/org.eclipse.sirius.tests.swtbot/src/org/eclipse/sirius/tests/swtbot/ExportDiagramsAsImagesTest.java
+++ b/plugins/org.eclipse.sirius.tests.swtbot/src/org/eclipse/sirius/tests/swtbot/ExportDiagramsAsImagesTest.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2010, 2016 THALES GLOBAL SERVICES.
+ * Copyright (c) 2010, 2018 THALES GLOBAL SERVICES.
* 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
@@ -12,6 +12,7 @@ package org.eclipse.sirius.tests.swtbot;
import java.util.List;
+import org.eclipse.sirius.business.api.session.Session;
import org.eclipse.sirius.diagram.DDiagram;
import org.eclipse.sirius.tests.support.api.EclipseTestsSupportHelper;
import org.eclipse.sirius.tests.support.api.TestsUtil;
@@ -549,6 +550,10 @@ public class ExportDiagramsAsImagesTest extends AbstractSiriusSwtBotGefTestCase
bot.comboBox(1).setSelection(imageExtension);
bot.button("OK").click();
SWTBotUtils.waitAllUiEvents();
+ // The session should still be opened after having performed an export as image.
+ Session openedSession = localSession.getOpenedSession();
+ assertNotNull("The session should be opened", openedSession);
+ assertTrue("The session should be opened", openedSession.isOpen());
}
private void exportAsImageFromModelContentView(String imageExtension, String rootElementName) throws Exception {

Back to the top