mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-02-04 23:39:07 +07:00
[ml-tests] make login test more stable
GitOrigin-RevId: 9521106ddfb16f67b2b312f9d343327ccd1e4353
This commit is contained in:
committed by
intellij-monorepo-bot
parent
f900e0625a
commit
281b7dafbe
@@ -1005,4 +1005,8 @@ fun <T : CommandChain> T.repeatCommand(times: Int, commandChain: (CommandChain)
|
||||
fun <T : CommandChain> T.createScratchFile(filename: String, content: String): T = apply {
|
||||
val modifiedContent = content.replace("\n", "\\n").replace(" ", "_")
|
||||
addCommand("${CMD_PREFIX}createScratchFile $filename $modifiedContent")
|
||||
}
|
||||
|
||||
fun <T : CommandChain> T.disableKotlinNotification(): T = apply {
|
||||
addCommand("${CMD_PREFIX}disableKotlinNotification")
|
||||
}
|
||||
@@ -109,7 +109,8 @@ public final class BaseCommandProvider implements CommandProvider {
|
||||
Map.entry(WaitForEDTQueueUnstuckCommand.PREFIX, WaitForEDTQueueUnstuckCommand::new),
|
||||
Map.entry(CreateScratchFile.PREFIX, CreateScratchFile::new),
|
||||
Map.entry(StoreHighlightingResultsCommand.PREFIX, StoreHighlightingResultsCommand::new),
|
||||
Map.entry(AddContentRootToModule.PREFIX, AddContentRootToModule::new)
|
||||
Map.entry(AddContentRootToModule.PREFIX, AddContentRootToModule::new),
|
||||
Map.entry(DisableKotlinNotificationCommand.PREFIX, DisableKotlinNotificationCommand::new)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.jetbrains.performancePlugin.commands
|
||||
|
||||
import com.intellij.ide.util.PropertiesComponent
|
||||
import com.intellij.openapi.ui.playback.PlaybackContext
|
||||
|
||||
private const val NOTIFICATION_PROPERTIES_KEY = "kotlin.code.style.migration.dialog.show.count"
|
||||
|
||||
class DisableKotlinNotificationCommand(text: String, line: Int) : PerformanceCommandCoroutineAdapter(text, line) {
|
||||
companion object {
|
||||
const val NAME: String = "disableKotlinNotification"
|
||||
const val PREFIX: String = CMD_PREFIX + NAME
|
||||
}
|
||||
|
||||
override suspend fun doExecute(context: PlaybackContext) {
|
||||
PropertiesComponent.getInstance().setValue(NOTIFICATION_PROPERTIES_KEY, Integer.MAX_VALUE, 0)
|
||||
}
|
||||
|
||||
override fun getName(): String {
|
||||
return NAME
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user