Skip to content

Commit e4e7e2d

Browse files
committed
build
1 parent a9fb14c commit e4e7e2d

File tree

9 files changed

+17
-79
lines changed

9 files changed

+17
-79
lines changed

plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/learn/LearnCodeWhispererEditor.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import com.intellij.ui.dsl.builder.BottomGap
1717
import com.intellij.ui.dsl.builder.Panel
1818
import com.intellij.ui.dsl.builder.TopGap
1919
import com.intellij.ui.dsl.builder.panel
20-
import com.intellij.ui.dsl.gridLayout.Gaps
20+
import com.intellij.ui.dsl.gridLayout.UnscaledGaps
2121
import icons.AwsIcons
2222
import software.aws.toolkits.jetbrains.services.codewhisperer.learn.LearnCodeWhispererUIComponents.examplesDescriptionPanel
2323
import software.aws.toolkits.jetbrains.services.codewhisperer.learn.LearnCodeWhispererUIComponents.tryExamplePanel
@@ -29,7 +29,7 @@ class LearnCodeWhispererEditor(val project: Project, val virtualFile: VirtualFil
2929
private val contentPanel = panel {
3030
row {
3131
panel {
32-
customize(Gaps(20, 50, 0, 0))
32+
customize(UnscaledGaps(20, 50, 0, 0))
3333
row {
3434
icon(AwsIcons.Logos.AWS_Q_GRADIENT)
3535

@@ -46,7 +46,7 @@ class LearnCodeWhispererEditor(val project: Project, val virtualFile: VirtualFil
4646
row {
4747
// Single panel
4848
panel {
49-
customize(Gaps(0, 50, 0, 0))
49+
customize(UnscaledGaps(0, 50, 0, 0))
5050
align(AlignY.TOP)
5151

5252
subtitle(message("codewhisperer.learn_page.examples.title")).bottomGap(BottomGap.MEDIUM)

plugins/core/jetbrains-community/src/software/aws/toolkits/jetbrains/PluginVersionChecker.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import com.intellij.notification.SingletonNotificationManager
1212
import com.intellij.openapi.application.ApplicationManager
1313
import com.intellij.openapi.application.ex.ApplicationManagerEx
1414
import com.intellij.openapi.progress.EmptyProgressIndicator
15-
import kotlinx.coroutines.CoroutineScope
1615
import software.aws.toolkits.core.utils.error
1716
import software.aws.toolkits.core.utils.getLogger
1817
import software.aws.toolkits.core.utils.info
@@ -24,7 +23,7 @@ import software.aws.toolkits.resources.AwsCoreBundle
2423
import javax.swing.SwingUtilities
2524

2625
class PluginVersionChecker : ApplicationInitializedListener {
27-
override suspend fun execute(asyncScope: CoroutineScope) {
26+
override suspend fun execute() {
2827
if (ApplicationManager.getApplication().isHeadlessEnvironment) {
2928
LOG.info { "Skipping due to headless environment" }
3029
return

plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/startup/PluginCoreEnforcementActivity.kt renamed to plugins/toolkit/jetbrains-core/src-233-241/software/aws/toolkits/jetbrains/core/startup/PluginCoreEnforcementActivity.kt/PluginCoreEnforcementActivity.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import org.slf4j.LoggerFactory
1515
class PluginCoreEnforcementActivity : ApplicationInitializedListener {
1616

1717
@Suppress("LazyLog")
18-
override suspend fun execute(asyncScope: CoroutineScope) {
18+
override suspend fun execute() {
1919
// can't reference anything in core
2020
val log = LoggerFactory.getLogger(this::class.java)
2121

plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/gettingstarted/editor/GettingStartedPanel.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ import com.intellij.ui.dsl.builder.Panel
3030
import com.intellij.ui.dsl.builder.TopGap
3131
import com.intellij.ui.dsl.builder.actionListener
3232
import com.intellij.ui.dsl.builder.panel
33-
import com.intellij.ui.dsl.gridLayout.Gaps
33+
import com.intellij.ui.dsl.gridLayout.UnscaledGaps
3434
import com.intellij.util.Alarm
3535
import com.intellij.util.ui.JBFont
3636
import com.intellij.util.ui.JBUI
@@ -1109,7 +1109,7 @@ class GettingStartedPanel(
11091109
// Image.SCALE_DEFAULT is the only valid parameter for gifs
11101110
.getScaledInstance(PANEL_WIDTH - (indentSize * 2), -1, if (path.endsWith("gif")) Image.SCALE_DEFAULT else Image.SCALE_SMOOTH)
11111111
cell(JLabel(ImageIcon(image)))
1112-
.customize(Gaps.EMPTY)
1112+
.customize(UnscaledGaps.EMPTY)
11131113
}
11141114
}
11151115
}

plugins/toolkit/jetbrains-gateway/src/software/aws/toolkits/jetbrains/gateway/CawsConnectorViewPanels.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -489,8 +489,7 @@ class EnvironmentDetailsPanel(private val context: CawsSettings, lifetime: Lifet
489489
panel {
490490
row(message("caws.workspace.details.backend_toolkit_location")) {
491491
textFieldWithBrowseButton(
492-
message("caws.workspace.details.toolkit_location"),
493-
fileChooserDescriptor = FileChooserDescriptorFactory.createSingleFileDescriptor()
492+
FileChooserDescriptorFactory.createSingleFileDescriptor()
494493
).bindText(context::toolkitLocation)
495494
}
496495

plugins/toolkit/jetbrains-rider/it/software/aws/toolkits/jetbrains/services/lambda/dotnet/DotnetLocalLambdaRunConfigurationIntegrationTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ abstract class DotnetLocalLambdaRunConfigurationIntegrationTestBase(private val
106106

107107
@Test
108108
fun samIsExecutedWithFileInput() {
109-
val input = Files.createTempFile(tempTestDirectory.toPath(), "tmp", null).also {
109+
val input = Files.createTempFile("tmp", null).also {
110110
it.writeText("Hello World")
111111
}
112112

plugins/toolkit/jetbrains-rider/tst/base/AwsReuseSolutionTestBase.kt

Lines changed: 7 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -3,61 +3,21 @@
33

44
package base
55

6-
import com.intellij.ide.GeneralSettings
7-
import com.intellij.openapi.project.Project
86
import com.jetbrains.rider.projectView.solutionDirectory
9-
import com.jetbrains.rider.test.base.BaseTestWithSolutionBase
7+
import com.jetbrains.rider.test.base.BaseTestWithSolution
108
import com.jetbrains.rider.test.debugger.XDebuggerTestHelper
119
import com.jetbrains.rider.test.scriptingApi.getVirtualFileFromPath
12-
import com.jetbrains.rider.test.scriptingApi.useCachedTemplates
13-
import org.testng.annotations.AfterClass
14-
import org.testng.annotations.BeforeClass
15-
import software.aws.toolkits.jetbrains.utils.OpenSolutionFileParams
16-
import software.aws.toolkits.jetbrains.utils.openSolutionFile
17-
import java.io.File
18-
import java.time.Duration
1910
/**
2011
* Base test class that uses the same solution per test class.
2112
* Solution re-open logic takes time. We can avoid this by using the same solution instance per every test in a class
2213
*/
23-
abstract class AwsReuseSolutionTestBase : BaseTestWithSolutionBase() {
24-
25-
private var myProject: Project? = null
26-
var project: Project
27-
get() = this.myProject!!
28-
set(value) {
29-
this.myProject = value
30-
}
31-
32-
protected open val waitForCaches: Boolean get() = false
33-
protected open val persistCaches: Boolean get() = false
34-
protected open val restoreNuGetPackages: Boolean get() = false
14+
abstract class AwsReuseSolutionTestBase : BaseTestWithSolution() {
15+
override val waitForCaches: Boolean get() = false
16+
override val persistCaches: Boolean get() = false
17+
override val restoreNuGetPackages: Boolean get() = false
3518

3619
protected abstract fun getSolutionDirectoryName(): String
3720

38-
protected open fun getCustomSolutionFileName(): String? = null
39-
protected open fun preprocessTempDirectory(tempDir: File) {}
40-
41-
// TODO: Remove when https://youtrack.jetbrains.com/issue/RIDER-47995 is fixed FIX_WHEN_MIN_IS_213
42-
@BeforeClass
43-
fun allowDotnetRoots() {
44-
allowCustomDotnetRoots()
45-
}
46-
47-
@BeforeClass(alwaysRun = true)
48-
fun setUpClassSolution() {
49-
openSolution(getSolutionDirectoryName())
50-
}
51-
52-
@AfterClass(alwaysRun = true)
53-
fun closeSolution() {
54-
try {
55-
closeSolutionAndResetSettings(myProject)
56-
} finally {
57-
myProject = null
58-
}
59-
}
60-
6121
// 15 is a magic number (it's the return statement since they are all the same), but the only
6222
// example of it used that I could find it is used that way:
6323
// https://github.com/JetBrains/fsharp-support/blob/93ab17493a34a0bc0fd4c70b11adde02f81455c4/rider-fsharp/src/test/kotlin/debugger/AsyncDebuggerTest.kt#L6
@@ -67,21 +27,6 @@ abstract class AwsReuseSolutionTestBase : BaseTestWithSolutionBase() {
6727
XDebuggerTestHelper.toggleBreakpoint(project, getVirtualFileFromPath("src/HelloWorld/Function.cs", project.solutionDirectory), line - 1)
6828
}
6929

70-
private fun openSolution(solutionDirName: String) {
71-
GeneralSettings.getInstance().isConfirmExit = false
72-
73-
val params = OpenSolutionFileParams()
74-
params.backendLoadedTimeout = backendStartTimeout
75-
params.customSolutionName = getCustomSolutionFileName()
76-
params.preprocessTempDirectory = { preprocessTempDirectory(it) }
77-
params.persistCaches = persistCaches
78-
params.waitForCaches = waitForCaches
79-
params.restoreNuGetPackages = restoreNuGetPackages
80-
81-
useCachedTemplates = false
82-
83-
myProject = openSolution(openSolutionFile(solutionDirName), params)
84-
}
85-
86-
override val backendShellLoadTimeout: Duration = backendStartTimeout
30+
override val testSolution = getSolutionDirectoryName()
31+
override val backendLoadedTimeout = backendStartTimeout
8732
}

plugins/toolkit/jetbrains-rider/tst/software/aws/toolkits/jetbrains/services/lambda/completion/DotNetHandlerCompletionTest.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,6 @@ import java.time.Duration
1717

1818
class DotNetHandlerCompletionTest : BaseTestWithSolution() {
1919
override val backendLoadedTimeout: Duration = backendStartTimeout
20-
override val backendShellLoadTimeout: Duration = backendStartTimeout
21-
22-
override fun getSolutionDirectoryName(): String = ""
2320

2421
override val waitForCaches = true
2522

plugins/toolkit/jetbrains-rider/tst/software/aws/toolkits/jetbrains/services/lambda/dotnet/LambdaGutterMarkHighlightingTest.kt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@ class LambdaGutterMarkHighlightingTest : BaseTestWithMarkup() {
1919
}
2020

2121
override val backendLoadedTimeout: Duration = backendStartTimeout
22-
override val backendShellLoadTimeout: Duration = backendStartTimeout
23-
24-
override fun getSolutionDirectoryName(): String = "SamHelloWorldApp"
22+
override val testSolution = "SamHelloWorldApp"
2523

2624
@Test
2725
fun testClass_FunctionClass_Detected() = verifyLambdaGutterMark()

0 commit comments

Comments
 (0)