diff options
author | Mathias Kinzler | 2011-03-31 18:24:27 +0000 |
---|---|---|
committer | Mathias Kinzler | 2011-03-31 18:24:27 +0000 |
commit | 19a693daeb5c3894c3d8ab624d70932dc40aa093 (patch) | |
tree | 1007fa8bae781737e59ba1ccde9ab06ce82e8ad7 /org.eclipse.egit.ui.test/src/org | |
parent | de0e418f8e299fea0d0b94442d02552a485233d6 (diff) | |
download | egit-19a693daeb5c3894c3d8ab624d70932dc40aa093.tar.gz egit-19a693daeb5c3894c3d8ab624d70932dc40aa093.tar.xz egit-19a693daeb5c3894c3d8ab624d70932dc40aa093.zip |
Stabilize SynchronizeViewTests
Removes a few seemingly unneeded calls to methods that grab focus
aggressively.
This makes the whole test class behave much more stable, as the window
in which the tests are running is not jumping to the front (at least
not on my Windows 7 installation).
Change-Id: I3d181736bbd9ae566003975a7607506a976ea4c3
Signed-off-by: Mathias Kinzler <mathias.kinzler@sap.com>
Diffstat (limited to 'org.eclipse.egit.ui.test/src/org')
-rw-r--r-- | org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/SynchronizeViewTest.java | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/SynchronizeViewTest.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/SynchronizeViewTest.java index 97b1968181..ecabbac132 100644 --- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/SynchronizeViewTest.java +++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/SynchronizeViewTest.java @@ -381,7 +381,6 @@ public class SynchronizeViewTest extends LocalRepositoryTestCase { workingTree.expand().getNode(name).doubleClick(); SWTBotEditor editor = bot.editorByTitle(name); - editor.setFocus(); // the WidgetNotFoundException will be thrown when widget with given content cannot be not found SWTBotStyledText left = editor.bot().styledText(content); @@ -559,8 +558,7 @@ public class SynchronizeViewTest extends LocalRepositoryTestCase { boolean includeLocal) throws InterruptedException { showDialog(projectName, "Team", "Synchronize..."); - bot.shell("Synchronize repository: " + repo + File.separator + ".git") - .activate(); + bot.shell("Synchronize repository: " + repo + File.separator + ".git"); if (!includeLocal) bot.checkBox( @@ -642,10 +640,7 @@ public class SynchronizeViewTest extends LocalRepositoryTestCase { SWTBotTreeItem folderNode = waitForNodeWithText(projNode, FOLDER); waitForNodeWithText(folderNode, fileName).doubleClick(); - SWTBotEditor editor = bot.editorByTitle(fileName); - editor.toTextEditor().setFocus(); - - return editor; + return bot.editorByTitle(fileName); } private SWTBotTreeItem waitForNodeWithText(SWTBotTree tree, String name) { @@ -675,10 +670,7 @@ public class SynchronizeViewTest extends LocalRepositoryTestCase { SWTBotTreeItem folderTree = waitForNodeWithText(projectTree, FOLDER); waitForNodeWithText(folderTree, FILE1).doubleClick(); - SWTBotEditor editor = bot.editorByTitle(FILE1); - editor.toTextEditor().setFocus(); - - return editor; + return bot.editorByTitle(FILE1); } } |