findbugs
[utils] / support / general / src / test / java / org / wamblee / concurrency / ReadWriteLockTest.java
index 3dc5c95abee49ca7bcb08fa5964ed7e53edc2055..0cb27433d1f7dcbf7555e9ec195e45f609e00ea0 100644 (file)
@@ -466,7 +466,7 @@ class ReadLocker implements Runnable {
         try {
             Thread.sleep(sleepTime);
         } catch (InterruptedException e) {
-            ReadWriteLockTest.fail("ReadLocker thread was interrupted." +
+            throw new RuntimeException("ReadLocker thread was interrupted." +
                 Thread.currentThread());
         }
 
@@ -499,7 +499,7 @@ class WriteLocker implements Runnable {
         try {
             Thread.sleep(sleepTime);
         } catch (InterruptedException e) {
-            ReadWriteLockTest.fail("WriteLocker thread was interrupted: " +
+            throw new RuntimeException("WriteLocker thread was interrupted: " +
                 Thread.currentThread());
         }