Skip to content

Commit c974d32

Browse files
committed
tst
1 parent 808f979 commit c974d32

File tree

4 files changed

+23
-11
lines changed

4 files changed

+23
-11
lines changed

buildSrc/settings.gradle.kts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,5 +43,11 @@ dependencyResolutionManagement {
4343
includeGroupByRegex("org\\.jetbrains\\.intellij\\.platform.*")
4444
}
4545
}
46+
maven {
47+
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
48+
content {
49+
includeGroupByRegex("org\\.mockito\\.kotlin")
50+
}
51+
}
4652
}
4753
}

gradle/libs.versions.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ kotlin = "2.1.20"
2424
kotlinCoroutines = "1.8.0"
2525
lsp4j = "0.24.0"
2626
mockito = "5.12.0"
27-
mockitoKotlin = "5.4.0"
27+
mockitoKotlin = "5.4.1-SNAPSHOT"
2828
mockk = "1.13.17"
2929
nimbus-jose-jwt = "9.40"
3030
node-gradle = "7.0.2"

plugins/amazonq/codewhisperer/jetbrains-community/tst/software/aws/toolkits/jetbrains/services/codewhisperer/CodeWhispererTestBase.kt

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -313,15 +313,7 @@ open class CodeWhispererTestBase {
313313
val psiFileCaptor = argumentCaptor<PsiFile>()
314314
val latencyContextCaptor = argumentCaptor<LatencyContext>()
315315

316-
wheneverBlocking {
317-
codewhispererService.getRequestContext(
318-
triggerTypeCaptor.capture(),
319-
editorCaptor.capture(),
320-
projectCaptor.capture(),
321-
psiFileCaptor.capture(),
322-
latencyContextCaptor.capture()
323-
)
324-
}.doSuspendableAnswer {
316+
doSuspendableAnswer {
325317
val requestContext = codewhispererService.getRequestContext(
326318
triggerTypeCaptor.firstValue,
327319
editorCaptor.firstValue,
@@ -331,7 +323,15 @@ open class CodeWhispererTestBase {
331323
)
332324
projectRule.fixture.type(userInput)
333325
requestContext
334-
}.thenCallRealMethod()
326+
}.wheneverBlocking(codewhispererService) {
327+
getRequestContext(
328+
triggerTypeCaptor.capture(),
329+
editorCaptor.capture(),
330+
projectCaptor.capture(),
331+
psiFileCaptor.capture(),
332+
latencyContextCaptor.capture()
333+
)
334+
}
335335
}
336336

337337
fun mockLspInlineCompletionResponse(response: InlineCompletionListWithReferences) {

settings.gradle.kts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ dependencyResolutionManagement {
3838
repositories {
3939
codeArtifactMavenRepo()
4040
mavenCentral()
41+
maven {
42+
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
43+
content {
44+
includeGroupByRegex("org\\.mockito\\.kotlin")
45+
}
46+
}
4147

4248
intellijPlatform {
4349
defaultRepositories()

0 commit comments

Comments
 (0)