File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
jetbrains-core/it/software/aws/toolkits/jetbrains/services/codewhisperer Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ import com.intellij.testFramework.runInEdtAndWait
15
15
import kotlinx.coroutines.runBlocking
16
16
import org.assertj.core.api.Assertions.assertThat
17
17
import org.junit.After
18
+ import org.junit.Assume.assumeTrue
18
19
import org.junit.Before
19
20
import org.junit.Rule
20
21
import org.mockito.kotlin.any
@@ -81,6 +82,7 @@ open class CodeWhispererIntegrationTestBase(val projectRule: CodeInsightTestFixt
81
82
@Suppress(" UnreachableCode" )
82
83
@Before
83
84
open fun setUp () {
85
+ assumeTrue(" CI doesn't have Builder ID credentials" , System .getenv(" CI" ).isNullOrBlank())
84
86
MockClientManager .useRealImplementations(disposableRule.disposable)
85
87
86
88
loginSso(projectRule.project, SONO_URL )
@@ -138,9 +140,17 @@ open class CodeWhispererIntegrationTestBase(val projectRule: CodeInsightTestFixt
138
140
@After
139
141
open fun tearDown () {
140
142
runInEdtAndWait {
141
- stateManager.loadState(originalExplorerActionState)
142
- settingsManager.loadState(originalSettings)
143
- popupManager.reset()
143
+ if (::stateManager.isInitialized) {
144
+ stateManager.loadState(originalExplorerActionState)
145
+ }
146
+
147
+ if (::settingsManager.isInitialized) {
148
+ settingsManager.loadState(originalSettings)
149
+ }
150
+
151
+ if (::popupManager.isInitialized) {
152
+ popupManager.reset()
153
+ }
144
154
}
145
155
}
146
156
You can’t perform that action at this time.
0 commit comments