aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-process/src
diff options
context:
space:
mode:
authorDavid Gageot <david@gageot.net>2015-05-07 18:46:24 +0200
committerDavid Gageot <david@gageot.net>2015-05-07 18:46:24 +0200
commit0858c3827dead29a8c0d7cceb3e5cae525b29264 (patch)
treeb9a275bd8425d3b4cd29924e2ae1ee1dbfd16639 /server/sonar-process/src
parent35fdca5b017a737c9b8eb3e43c1250e739590175 (diff)
downloadsonarqube-0858c3827dead29a8c0d7cceb3e5cae525b29264.tar.gz
sonarqube-0858c3827dead29a8c0d7cceb3e5cae525b29264.zip
Throw actual exception
Diffstat (limited to 'server/sonar-process/src')
-rw-r--r--server/sonar-process/src/test/java/org/sonar/process/StopWatcherTest.java4
-rw-r--r--server/sonar-process/src/test/java/org/sonar/process/StopperThreadTest.java4
2 files changed, 4 insertions, 4 deletions
diff --git a/server/sonar-process/src/test/java/org/sonar/process/StopWatcherTest.java b/server/sonar-process/src/test/java/org/sonar/process/StopWatcherTest.java
index 37b929f0588..d403c0f5e30 100644
--- a/server/sonar-process/src/test/java/org/sonar/process/StopWatcherTest.java
+++ b/server/sonar-process/src/test/java/org/sonar/process/StopWatcherTest.java
@@ -26,7 +26,7 @@ import static org.mockito.Mockito.*;
public class StopWatcherTest {
@Test(timeout = 1000L)
- public void stop_if_receive_command() throws Exception {
+ public void stop_if_receive_command() throws InterruptedException {
ProcessCommands commands = mock(ProcessCommands.class);
when(commands.askedForStop()).thenReturn(false).thenReturn(true);
Stoppable stoppable = mock(Stoppable.class);
@@ -39,7 +39,7 @@ public class StopWatcherTest {
}
@Test(timeout = 1000L)
- public void stop_watching_on_interruption() throws Exception {
+ public void stop_watching_on_interruption() throws InterruptedException {
ProcessCommands commands = mock(ProcessCommands.class);
when(commands.askedForStop()).thenReturn(false);
Stoppable stoppable = mock(Stoppable.class);
diff --git a/server/sonar-process/src/test/java/org/sonar/process/StopperThreadTest.java b/server/sonar-process/src/test/java/org/sonar/process/StopperThreadTest.java
index c174b3012af..539b29681b7 100644
--- a/server/sonar-process/src/test/java/org/sonar/process/StopperThreadTest.java
+++ b/server/sonar-process/src/test/java/org/sonar/process/StopperThreadTest.java
@@ -28,7 +28,7 @@ import static org.mockito.Mockito.*;
public class StopperThreadTest {
@Test(timeout = 3000L)
- public void stop_in_a_timely_fashion() throws Exception {
+ public void stop_in_a_timely_fashion() throws InterruptedException {
ProcessCommands commands = mock(ProcessCommands.class);
Monitored monitored = mock(Monitored.class);
@@ -42,7 +42,7 @@ public class StopperThreadTest {
}
@Test(timeout = 3000L)
- public void stop_timeout() throws Exception {
+ public void stop_timeout() throws InterruptedException {
ProcessCommands commands = mock(ProcessCommands.class);
Monitored monitored = mock(Monitored.class);
doAnswer(new Answer() {