Code insight: "Generate..." actions for test framework support methods
#KT-9355 Fixed
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$Data
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$Data
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.DataProvider
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {
|
||||
@DataProvider(name = "Name")
|
||||
fun Name(): Array<Array<Any>> {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$SetUp
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$SetUp
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.BeforeMethod
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {
|
||||
@BeforeMethod
|
||||
fun setUp() {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$SetUp
|
||||
// NOT_APPLICABLE
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.BeforeMethod
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
@BeforeMethod
|
||||
fun setUp() {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$SetUp
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
open class A {
|
||||
open fun setUp() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Test class B : A() {<caret>
|
||||
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$SetUp
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.BeforeMethod
|
||||
import org.testng.annotations.Test
|
||||
|
||||
open class A {
|
||||
open fun setUp() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Test class B : A() {
|
||||
@BeforeMethod
|
||||
override fun setUp() {
|
||||
super.setUp()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$TearDown
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$TearDown
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.AfterMethod
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {
|
||||
@AfterMethod
|
||||
fun tearDown() {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$TearDown
|
||||
// NOT_APPLICABLE
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.AfterMethod
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
@AfterMethod
|
||||
fun tearDown() {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$Test
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {<caret>
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
// ACTION_CLASS: org.jetbrains.kotlin.idea.actions.generate.KotlinGenerateTestSupportActionBase$Test
|
||||
// CONFIGURE_LIBRARY: TestNG@plugins/testng/lib/testng.jar
|
||||
import org.testng.annotations.Test
|
||||
|
||||
@Test class A {
|
||||
@Test
|
||||
fun testName() {
|
||||
throw UnsupportedOperationException()
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user