directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r1681430 - /directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java
Date Sun, 24 May 2015 10:14:50 GMT
Author: seelmann
Date: Sun May 24 10:14:50 2015
New Revision: 1681430

URL: http://svn.apache.org/r1681430
Log:
Open prefernces dialog is different on Mac

Modified:
    directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java

Modified: directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java?rev=1681430&r1=1681429&r2=1681430&view=diff
==============================================================================
--- directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java
(original)
+++ directory/studio/trunk/tests/test.integration.ui/src/main/java/org/apache/directory/studio/test/integration/ui/bots/StudioBot.java
Sun May 24 10:14:50 2015
@@ -20,12 +20,14 @@
 package org.apache.directory.studio.test.integration.ui.bots;
 
 
+import org.eclipse.swt.SWT;
 import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Shell;
 import org.eclipse.swtbot.swt.finder.SWTBot;
 import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException;
 import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
 import org.eclipse.swtbot.swt.finder.results.VoidResult;
+import org.eclipse.swtbot.swt.finder.utils.SWTUtils;
 import org.eclipse.ui.IViewReference;
 import org.eclipse.ui.IWorkbench;
 import org.eclipse.ui.IWorkbenchPage;
@@ -143,7 +145,14 @@ public class StudioBot
 
     public PreferencesBot openPreferences()
     {
-        new SWTBot().menu( "Window" ).menu( "Preferences" ).click();
+        if ( SWTUtils.isMac() )
+        {
+            new SWTBot().activeShell().pressShortcut( SWT.COMMAND, ',' );
+        }
+        else
+        {
+            new SWTBot().menu( "Window" ).menu( "Preferences" ).click();
+        }
         return new PreferencesBot();
     }
 



Mime
View raw message