diff options
Diffstat (limited to 'sonar-duplications')
-rw-r--r-- | sonar-duplications/src/test/java/org/sonar/duplications/detector/DetectorTestCase.java | 2 | ||||
-rw-r--r-- | sonar-duplications/src/test/java/org/sonar/duplications/junit/TestNamePrinter.java | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/sonar-duplications/src/test/java/org/sonar/duplications/detector/DetectorTestCase.java b/sonar-duplications/src/test/java/org/sonar/duplications/detector/DetectorTestCase.java index 100b09d1be8..261eacfe314 100644 --- a/sonar-duplications/src/test/java/org/sonar/duplications/detector/DetectorTestCase.java +++ b/sonar-duplications/src/test/java/org/sonar/duplications/detector/DetectorTestCase.java @@ -34,11 +34,11 @@ import java.util.Collections; import java.util.Iterator; import java.util.List; +import static org.hamcrest.CoreMatchers.hasItem; import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.sameInstance; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertThat; -import static org.junit.matchers.JUnitMatchers.hasItem; import static org.mockito.Mockito.spy; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.verifyNoMoreInteractions; diff --git a/sonar-duplications/src/test/java/org/sonar/duplications/junit/TestNamePrinter.java b/sonar-duplications/src/test/java/org/sonar/duplications/junit/TestNamePrinter.java index 8064c822f34..4bca9becb43 100644 --- a/sonar-duplications/src/test/java/org/sonar/duplications/junit/TestNamePrinter.java +++ b/sonar-duplications/src/test/java/org/sonar/duplications/junit/TestNamePrinter.java @@ -19,14 +19,14 @@ */ package org.sonar.duplications.junit; -import org.junit.rules.TestWatchman; -import org.junit.runners.model.FrameworkMethod; +import org.junit.rules.TestWatcher; +import org.junit.runner.Description; -public class TestNamePrinter extends TestWatchman { +public class TestNamePrinter extends TestWatcher { @Override - public void starting(FrameworkMethod method) { - System.out.println("Executing " + method.getName()); + protected void starting(Description description) { + System.out.println("Executing " + description.getMethodName()); } } |