Skip to content

Commit 3fee712

Browse files
committed
Revert "test"
This reverts commit 4910fc7.
1 parent f085ce8 commit 3fee712

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

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

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@ import software.aws.toolkits.jetbrains.utils.rules.HeavyJavaCodeInsightTestFixtu
6060
import software.aws.toolkits.jetbrains.utils.rules.addClass
6161
import software.aws.toolkits.jetbrains.utils.rules.addModule
6262
import software.aws.toolkits.jetbrains.utils.rules.addTestClass
63-
import java.util.concurrent.atomic.AtomicBoolean
6463
import kotlin.test.assertNotNull
6564

6665
class CodeWhispererFileContextProviderTest {
@@ -231,26 +230,6 @@ class CodeWhispererFileContextProviderTest {
231230
assertThat(serverContext.constructed()).hasSize(1)
232231

233232
whenever(providerContext.constructed()[0].queryInline(any(), any(), any())).thenThrow(RuntimeException("mock exception"))
234-
whenever(providerContext.constructed()[0].isIndexComplete).thenReturn(AtomicBoolean(true))
235-
236-
val result = controller.queryInline("query", "filePath")
237-
assertThat(result).isEmpty()
238-
}
239-
}
240-
}
241-
242-
@Test
243-
fun `projectContextController should return empty result if index is not ready`() = runTest {
244-
mockConstruction(ProjectContextProvider::class.java).use { providerContext ->
245-
mockConstruction(EncoderServer::class.java).use { serverContext ->
246-
assertThat(providerContext.constructed()).hasSize(0)
247-
assertThat(serverContext.constructed()).hasSize(0)
248-
val controller = ProjectContextController(project, TestScope())
249-
assertThat(providerContext.constructed()).hasSize(1)
250-
assertThat(serverContext.constructed()).hasSize(1)
251-
252-
whenever(providerContext.constructed()[0].queryInline(any(), any(), any())).thenReturn(listOf(InlineBm25Chunk("foo", "path", 0.0)))
253-
whenever(providerContext.constructed()[0].isIndexComplete).thenReturn(AtomicBoolean(false))
254233

255234
val result = controller.queryInline("query", "filePath")
256235
assertThat(result).isEmpty()

0 commit comments

Comments
 (0)