Author: DartPeng
Date: 2010-04-06 00:35:23 -0400 (Tue, 06 Apr 2010)
New Revision: 21274
Added:
workspace/dart/org.jboss.tools.smooks.ui.bot.test/src/org/jboss/tools/smooks/ui/bot/test/jira/BeanidIsLost_JBIDE6068.java
Log:
JBIDE-6068
Reproduct the bug
Added:
workspace/dart/org.jboss.tools.smooks.ui.bot.test/src/org/jboss/tools/smooks/ui/bot/test/jira/BeanidIsLost_JBIDE6068.java
===================================================================
---
workspace/dart/org.jboss.tools.smooks.ui.bot.test/src/org/jboss/tools/smooks/ui/bot/test/jira/BeanidIsLost_JBIDE6068.java
(rev 0)
+++
workspace/dart/org.jboss.tools.smooks.ui.bot.test/src/org/jboss/tools/smooks/ui/bot/test/jira/BeanidIsLost_JBIDE6068.java 2010-04-06
04:35:23 UTC (rev 21274)
@@ -0,0 +1,59 @@
+package org.jboss.tools.smooks.ui.bot.test.jira;
+
+import org.eclipse.core.runtime.Assert;
+import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor;
+import org.eclipse.swtbot.eclipse.gef.finder.SWTGefBot;
+import org.eclipse.swtbot.eclipse.gef.finder.widgets.SWTBotGefEditPart;
+import org.eclipse.swtbot.eclipse.gef.finder.widgets.SWTBotGefEditor;
+import org.eclipse.swtbot.swt.finder.SWTBot;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
+import org.jboss.tools.smooks.graphical.editors.TaskTypeManager;
+import org.jboss.tools.smooks.ui.bot.test.AbstractSmooksUIBotTest;
+
+/**
+ *
+ * @author Dart JBIDE-6068
+ */
+public class BeanidIsLost_JBIDE6068 extends AbstractSmooksUIBotTest {
+ private String fileName;
+
+ public void testThisBug() {
+
+ SWTGefBot gefBot = new SWTGefBot();
+
+ fileName = "bean-id-lost.xml";
+ this.newSmooksConfigFile(getTestProjectName(), fileName);
+ SWTBotEditor editor = bot.editorByTitle(fileName);
+ final SWTBot innerBot = editor.bot();
+
+ // add task node via pop menu
+ selectNode(innerBot, TaskTypeManager.TASK_ID_INPUT, 3);
+ SWTBotMenu addJavaMappingMenu = findProcessMapViewerContext(getGraph(innerBot),
"Java Mapping");
+ addJavaMappingMenu.click();
+
+ // select at the java mapping task
+ selectNode(innerBot, TaskTypeManager.TASK_ID_JAVA_MAPPING, 1);
+
+ SWTBotGefEditor editor1 = gefBot.gefEditor(fileName);
+
+ // add java class model via pop menu
+ editor1.rootEditPart().click();
+ editor1.clickContextMenu("Java Class ");
+
+ // open java bean creation dialog
+ bot.shell("New Java Class Model").activate();
+
+ // REPRODUCT THE BUG :
+
+ bot.textWithLabel("Java Class
:").setText("edi2java.example.model.Order");
+
+ bot.textWithLabel("Bean ID :").setText("this_test_beanid");
+
+ bot.button("Finish").click();
+
+ // to find the 'this_test_beanid' GEF edit part:
+ SWTBotGefEditPart part = editor1.getEditPart("this_test_beanid");
+
+ Assert.isNotNull(part , "Can't find the 'this_test_beanid' edit part ,
Bean ID IS LOST!!!");
+ }
+}
Property changes on:
workspace/dart/org.jboss.tools.smooks.ui.bot.test/src/org/jboss/tools/smooks/ui/bot/test/jira/BeanidIsLost_JBIDE6068.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain