From 5aad14ca8dde1d3c94d544da476e279d314c9874 Mon Sep 17 00:00:00 2001 From: Sophio Japharidze Date: Tue, 21 Nov 2023 10:56:52 +0100 Subject: [PATCH] Use latest SLCORE --- pom.xml | 2 +- .../ls/clientapi/SonarLintVSCodeClientTests.java | 4 ++-- .../ls/commands/ShowAllLocationsCommandTests.java | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/pom.xml b/pom.xml index 1e05e2c2e..6e9a010f4 100644 --- a/pom.xml +++ b/pom.xml @@ -24,7 +24,7 @@ 17 - 9.5.0.76145 + 9.5.0.76302 1.6.10 diff --git a/src/test/java/org/sonarsource/sonarlint/ls/clientapi/SonarLintVSCodeClientTests.java b/src/test/java/org/sonarsource/sonarlint/ls/clientapi/SonarLintVSCodeClientTests.java index b08f6794d..4641de774 100644 --- a/src/test/java/org/sonarsource/sonarlint/ls/clientapi/SonarLintVSCodeClientTests.java +++ b/src/test/java/org/sonarsource/sonarlint/ls/clientapi/SonarLintVSCodeClientTests.java @@ -383,7 +383,7 @@ void shouldForwardServerSentEvent() { void shouldForwardOpenIssueRequest() { var textRangeDto = new TextRangeDto(1, 2, 3, 4); var showIssueParams = new ShowIssueParams(textRangeDto, "connectionId", "rule:S1234", - "issueKey", FILE_PYTHON, "this is wrong", "29.09.2023", "print('ddd')", false, List.of()); + "issueKey", FILE_PYTHON, "branch", "1234", "this is wrong", "29.09.2023", "print('ddd')", false, List.of()); var fileUri = fileInAWorkspaceFolderPath.toUri(); when(bindingManager.serverPathToFileUri(showIssueParams.getServerRelativeFilePath())) @@ -406,7 +406,7 @@ void shouldForwardOpenIssueRequest() { void shouldNotForwardOpenIssueRequestWhenBindingDoesNotExist() { var textRangeDto = new TextRangeDto(1, 2, 3, 4); var showIssueParams = new ShowIssueParams(textRangeDto, "connectionId", "rule:S1234", - "issueKey", FILE_PYTHON, "this is wrong", "29.09.2023", "print('ddd')", false, List.of()); + "issueKey", FILE_PYTHON, "bb", null, "this is wrong", "29.09.2023", "print('ddd')", false, List.of()); var fileUri = fileInAWorkspaceFolderPath.toUri(); when(bindingManager.serverPathToFileUri(showIssueParams.getServerRelativeFilePath())) diff --git a/src/test/java/org/sonarsource/sonarlint/ls/commands/ShowAllLocationsCommandTests.java b/src/test/java/org/sonarsource/sonarlint/ls/commands/ShowAllLocationsCommandTests.java index b8b0b7c95..3b755d75a 100644 --- a/src/test/java/org/sonarsource/sonarlint/ls/commands/ShowAllLocationsCommandTests.java +++ b/src/test/java/org/sonarsource/sonarlint/ls/commands/ShowAllLocationsCommandTests.java @@ -130,7 +130,7 @@ void shouldBuildCommandParamsFromIssue() { void shouldBuildCommandParamsFromShowIssueParams() { var textRangeDto = new TextRangeDto(1, 0, 1, 13); var showIssueParams = new ShowIssueParams(textRangeDto, "connectionId", "rule:S1234", - "issueKey", "/src/java/main/myFile.py", "this is wrong", + "issueKey", "/src/java/main/myFile.py", "branch", "pr", "this is wrong", "29.09.2023", "print('1234')", false, List.of()); when(projectBindingManager.serverPathToFileUri(showIssueParams.getServerRelativeFilePath())).thenReturn(Optional.of(fileInAWorkspaceFolderPath.toUri())); @@ -144,7 +144,7 @@ void shouldBuildCommandParamsFromShowIssueParams() { void shouldBuildCommandParamsFromShowIssueParamsForFileLevelIssue() { var textRangeDto = new TextRangeDto(0, 0, 0, 0); var showIssueParams = new ShowIssueParams(textRangeDto, "connectionId", "rule:S1234", - "issueKey", "/src/java/main/myFile.py", "this is wrong", + "issueKey", "/src/java/main/myFile.py", "branch", null, "this is wrong", "29.09.2023", """ print('1234') print('aa') @@ -161,7 +161,7 @@ void shouldBuildCommandParamsFromShowIssueParamsForFileLevelIssue() { void shouldBuildCommandParamsFromShowIssueParamsForInvalidTextRange() { var textRangeDto = new TextRangeDto(-1, 0, -2, 0); var showIssueParams = new ShowIssueParams(textRangeDto, "connectionId", "rule:S1234", - "issueKey", "/src/java/main/myFile.py", "this is wrong", + "issueKey", "/src/java/main/myFile.py", "bb", "1234", "this is wrong", "29.09.2023", "print('1234')", false, List.of()); when(projectBindingManager.serverPathToFileUri(showIssueParams.getServerRelativeFilePath())).thenReturn(Optional.of(fileInAWorkspaceFolderPath.toUri())); @@ -181,7 +181,7 @@ void shouldBuildCommandParamsFromShowIssueParamsWithFlows() { var flow = new FlowDto(List.of(location1, location2)); var showIssueParams = new ShowIssueParams(textRangeDto1, "connectionId", "rule:S1234", - "issueKey", "/src/java/main/myFile.py", "this is wrong", "29.09.2023", + "issueKey", "/src/java/main/myFile.py", "main", "", "this is wrong", "29.09.2023", "print('1234')", false, List.of(flow)); when(projectBindingManager.serverPathToFileUri(showIssueParams.getServerRelativeFilePath())).thenReturn(Optional.of(fileInAWorkspaceFolderPath.toUri()));