File tree Expand file tree Collapse file tree 2 files changed +12
-21
lines changed
utbot-framework/src/main/kotlin/org/utbot/framework/codegen Expand file tree Collapse file tree 2 files changed +12
-21
lines changed Original file line number Diff line number Diff line change @@ -375,16 +375,21 @@ object TestNg : TestFramework(displayName = "TestNG") {
375
375
}
376
376
377
377
object Junit4 : TestFramework(" JUnit4" ) {
378
- private val parametrizedTestsNotSupportedError: Nothing = error(" Parametrized tests are not supported for JUnit4" )
378
+ private val parametrizedTestsNotSupportedError: Nothing
379
+ get() = error(" Parametrized tests are not supported for JUnit4" )
379
380
380
381
override val mainPackage: String = JUNIT4_PACKAGE
381
382
override val testAnnotation = " @$mainPackage .Test"
382
383
override val testAnnotationFqn: String = " $mainPackage .Test"
383
384
384
- override val parameterizedTestAnnotation = parametrizedTestsNotSupportedError
385
- override val parameterizedTestAnnotationFqn = parametrizedTestsNotSupportedError
386
- override val methodSourceAnnotation = parametrizedTestsNotSupportedError
387
- override val methodSourceAnnotationFqn = parametrizedTestsNotSupportedError
385
+ override val parameterizedTestAnnotation
386
+ get() = parametrizedTestsNotSupportedError
387
+ override val parameterizedTestAnnotationFqn
388
+ get() = parametrizedTestsNotSupportedError
389
+ override val methodSourceAnnotation
390
+ get() = parametrizedTestsNotSupportedError
391
+ override val methodSourceAnnotationFqn
392
+ get() = parametrizedTestsNotSupportedError
388
393
389
394
override val testAnnotationId = BuiltinClassId (
390
395
name = " $JUNIT4_PACKAGE .Test" ,
Original file line number Diff line number Diff line change @@ -215,21 +215,6 @@ internal abstract class TestFrameworkManager(val context: CgContext)
215
215
* Add a short test's description depending on the test framework type:
216
216
*/
217
217
abstract fun addTestDescription (description : String )
218
- // {
219
- // if (description == null) return
220
- // val testAnnotation =
221
- // collectedMethodAnnotations.singleOrNull { it.classId == testFramework.testAnnotationId }
222
- //
223
- // val descriptionArgument = CgNamedAnnotationArgument("description", stringLiteral(description))
224
- // if (testAnnotation is CgMultipleArgsAnnotation) {
225
- // testAnnotation.arguments += descriptionArgument
226
- // } else {
227
- // collectedMethodAnnotations += CgMultipleArgsAnnotation(
228
- // testFramework.testAnnotationId,
229
- // mutableListOf(descriptionArgument)
230
- // )
231
- // }
232
- // }
233
218
234
219
abstract fun disableTestMethod (reason : String )
235
220
@@ -399,7 +384,8 @@ internal class TestNgManager(context: CgContext) : TestFrameworkManager(context)
399
384
}
400
385
401
386
internal class Junit4Manager (context : CgContext ) : TestFrameworkManager(context) {
402
- private val parametrizedTestsNotSupportedError: Nothing = error(" Parametrized tests are not supported for JUnit4" )
387
+ private val parametrizedTestsNotSupportedError: Nothing
388
+ get() = error(" Parametrized tests are not supported for JUnit4" )
403
389
404
390
override val dataProviderMethodsHolder
405
391
get() = parametrizedTestsNotSupportedError
You can’t perform that action at this time.
0 commit comments