diff options
author | Ketan Padegaonkar | 2010-11-06 16:08:36 +0000 |
---|---|---|
committer | Ketan Padegaonkar | 2010-11-06 16:08:36 +0000 |
commit | 5c2f1eaff66d8a1aa184727dbece8641f07b5820 (patch) | |
tree | 35f3d284448c9ff12dc4c1ecb0f88d18e7afe62a | |
parent | 74d9824800e47e32999cc95ffb3db97010099a11 (diff) | |
download | org.eclipse.swtbot-5c2f1eaff66d8a1aa184727dbece8641f07b5820.tar.gz org.eclipse.swtbot-5c2f1eaff66d8a1aa184727dbece8641f07b5820.tar.xz org.eclipse.swtbot-5c2f1eaff66d8a1aa184727dbece8641f07b5820.zip |
Reduce timeouts in certain places where the timeout is too high to improve build times.
3 files changed, 45 insertions, 0 deletions
diff --git a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotCheckBoxTest.java b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotCheckBoxTest.java index 0bf230e0..60b9bcd2 100644 --- a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotCheckBoxTest.java +++ b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotCheckBoxTest.java @@ -25,6 +25,9 @@ import org.eclipse.swtbot.swt.finder.SWTBot; import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; import org.eclipse.swtbot.swt.finder.finders.AbstractSWTTestCase; import org.eclipse.swtbot.swt.finder.finders.ControlFinder; +import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences; +import org.junit.After; +import org.junit.Before; import org.junit.Test; /** @@ -34,6 +37,18 @@ import org.junit.Test; public class SWTBotCheckBoxTest extends AbstractSWTTestCase { private SWTBot bot; + private long oldTimeout; + + @Before + public void lowerTimeout() { + this.oldTimeout = SWTBotPreferences.TIMEOUT; + SWTBotPreferences.TIMEOUT = 2000; + } + + @After + public void resetTimeout() { + SWTBotPreferences.TIMEOUT = oldTimeout; + } @Test public void clicksCheckBox() throws Exception { diff --git a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotRadioTest.java b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotRadioTest.java index 255281f5..58de259d 100644 --- a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotRadioTest.java +++ b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotRadioTest.java @@ -25,6 +25,9 @@ import org.eclipse.swtbot.swt.finder.SWTBot; import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; import org.eclipse.swtbot.swt.finder.finders.AbstractSWTTestCase; import org.eclipse.swtbot.swt.finder.finders.ControlFinder; +import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences; +import org.junit.After; +import org.junit.Before; import org.junit.Test; /** @@ -34,6 +37,18 @@ import org.junit.Test; public class SWTBotRadioTest extends AbstractSWTTestCase { private SWTBot bot; + private long oldTimeout; + + @Before + public void lowerTimeout() { + this.oldTimeout = SWTBotPreferences.TIMEOUT; + SWTBotPreferences.TIMEOUT = 2000; + } + + @After + public void resetTimeout() { + SWTBotPreferences.TIMEOUT = oldTimeout; + } @Test public void clicksCheckBox() throws Exception { diff --git a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotToggleButtonTest.java b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotToggleButtonTest.java index 22016157..9f358656 100644 --- a/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotToggleButtonTest.java +++ b/org.eclipse.swtbot.swt.finder.test/src/org/eclipse/swtbot/swt/finder/widgets/SWTBotToggleButtonTest.java @@ -25,6 +25,9 @@ import org.eclipse.swtbot.swt.finder.SWTBot; import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException; import org.eclipse.swtbot.swt.finder.finders.AbstractSWTTestCase; import org.eclipse.swtbot.swt.finder.finders.ControlFinder; +import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences; +import org.junit.After; +import org.junit.Before; import org.junit.Test; /** @@ -34,6 +37,18 @@ import org.junit.Test; public class SWTBotToggleButtonTest extends AbstractSWTTestCase { private SWTBot bot; + private long oldTimeout; + + @Before + public void lowerTimeout() { + this.oldTimeout = SWTBotPreferences.TIMEOUT; + SWTBotPreferences.TIMEOUT = 2000; + } + + @After + public void resetTimeout() { + SWTBotPreferences.TIMEOUT = oldTimeout; + } @Test public void clicksToggleButton() throws Exception { |