From 3872cf775d8a04b1d054a3cb9213cce7a5e4262b Mon Sep 17 00:00:00 2001 From: arus2023 Date: Thu, 5 Oct 2023 22:37:17 -0500 Subject: [PATCH] Removed 5 unnecessary stubbings in PerforceBlameCommandTest.java --- .../sonar/plugins/scm/perforce/PerforceBlameCommandTest.java | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/test/java/org/sonar/plugins/scm/perforce/PerforceBlameCommandTest.java b/src/test/java/org/sonar/plugins/scm/perforce/PerforceBlameCommandTest.java index 083f130..a62cd7b 100644 --- a/src/test/java/org/sonar/plugins/scm/perforce/PerforceBlameCommandTest.java +++ b/src/test/java/org/sonar/plugins/scm/perforce/PerforceBlameCommandTest.java @@ -75,28 +75,23 @@ public void testBlameSubmittedFile() throws Exception { // Changelist 3 is present in history IFileAnnotation line1ChangeList3 = mock(IFileAnnotation.class); - when(line1ChangeList3.getDepotPath()).thenReturn("foo/bar/src/Foo.java"); when(line1ChangeList3.getLower()).thenReturn(3); IFileAnnotation line2ChangeList3 = mock(IFileAnnotation.class); - when(line2ChangeList3.getDepotPath()).thenReturn("foo/bar/src/Foo.java"); when(line2ChangeList3.getLower()).thenReturn(3); // Changelist 4 is not present in history but can be fetched from server IFileAnnotation line3ChangeList4 = mock(IFileAnnotation.class); - when(line3ChangeList4.getDepotPath()).thenReturn("foo/bar/src/Foo.java"); when(line3ChangeList4.getLower()).thenReturn(4); // Changelist 5 is not present in history nor in server IFileAnnotation line4ChangeList5 = mock(IFileAnnotation.class); - when(line4ChangeList5.getDepotPath()).thenReturn("foo/bar/src/Foo.java"); when(line4ChangeList5.getLower()).thenReturn(5); // Put Changlist 4 again to verify we fetch only once from server IFileAnnotation line5ChangeList4 = mock(IFileAnnotation.class); - when(line5ChangeList4.getDepotPath()).thenReturn("foo/bar/src/Foo.java"); when(line5ChangeList4.getLower()).thenReturn(4); Map> result = new HashMap>();