i18n: add bundle for idea/testIntegration
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
button.text.cancel=Cancel
|
||||||
|
button.text.rewrite=Rewrite
|
||||||
|
message.text.create.test.in.the.same.source.root=Create test in the same source root?
|
||||||
|
message.text.kotlin.class=Kotlin class ''{0}'' already exists. Do you want to update it?
|
||||||
|
title.no.test.roots.found=No Test Roots Found
|
||||||
@@ -108,8 +108,8 @@ class KotlinCreateTestIntention : SelfTargetingRangeIntention<KtNamedDeclaration
|
|||||||
if (testFolders.isEmpty() && !propertiesComponent.getBoolean("create.test.in.the.same.root")) {
|
if (testFolders.isEmpty() && !propertiesComponent.getBoolean("create.test.in.the.same.root")) {
|
||||||
if (Messages.showOkCancelDialog(
|
if (Messages.showOkCancelDialog(
|
||||||
project,
|
project,
|
||||||
"Create test in the same source root?",
|
KotlinTestIntegrationBundle.message("message.text.create.test.in.the.same.source.root"),
|
||||||
"No Test Roots Found",
|
KotlinTestIntegrationBundle.message("title.no.test.roots.found"),
|
||||||
Messages.getQuestionIcon()
|
Messages.getQuestionIcon()
|
||||||
) != Messages.OK
|
) != Messages.OK
|
||||||
) return
|
) return
|
||||||
@@ -130,10 +130,10 @@ class KotlinCreateTestIntention : SelfTargetingRangeIntention<KtNamedDeclaration
|
|||||||
// TODO: Override dialog method when it becomes protected
|
// TODO: Override dialog method when it becomes protected
|
||||||
val answer = Messages.showYesNoDialog(
|
val answer = Messages.showYesNoDialog(
|
||||||
project,
|
project,
|
||||||
"Kotlin class '${existingClass.name}' already exists. Do you want to update it?",
|
KotlinTestIntegrationBundle.message("message.text.kotlin.class", existingClass.name.toString()),
|
||||||
CommonBundle.getErrorTitle(),
|
CommonBundle.getErrorTitle(),
|
||||||
"Rewrite",
|
KotlinTestIntegrationBundle.message("button.text.rewrite"),
|
||||||
"Cancel",
|
KotlinTestIntegrationBundle.message("button.text.cancel"),
|
||||||
Messages.getErrorIcon()
|
Messages.getErrorIcon()
|
||||||
)
|
)
|
||||||
if (answer == Messages.NO) return
|
if (answer == Messages.NO) return
|
||||||
|
|||||||
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package org.jetbrains.kotlin.idea.testIntegration
|
||||||
|
|
||||||
|
import org.jetbrains.annotations.NonNls
|
||||||
|
import org.jetbrains.annotations.PropertyKey
|
||||||
|
import org.jetbrains.kotlin.util.AbstractKotlinBundle
|
||||||
|
|
||||||
|
@NonNls
|
||||||
|
private const val BUNDLE = "messages.KotlinTestIntegrationBundle"
|
||||||
|
|
||||||
|
object KotlinTestIntegrationBundle : AbstractKotlinBundle(BUNDLE) {
|
||||||
|
@JvmStatic
|
||||||
|
fun message(@PropertyKey(resourceBundle = BUNDLE) key: String, vararg params: Any): String = getMessage(key, *params)
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user