From 90c4f65ed762f205cff8f1644c492c296378edad Mon Sep 17 00:00:00 2001 From: amandelpie Date: Wed, 26 Oct 2022 13:39:19 +0300 Subject: [PATCH] Write generated test method name to the UtExecution for the Sariff generation needs --- .../codegen/model/constructor/tree/CgMethodConstructor.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/utbot-framework/src/main/kotlin/org/utbot/framework/codegen/model/constructor/tree/CgMethodConstructor.kt b/utbot-framework/src/main/kotlin/org/utbot/framework/codegen/model/constructor/tree/CgMethodConstructor.kt index 92aeaf3b66..d32a1d1191 100644 --- a/utbot-framework/src/main/kotlin/org/utbot/framework/codegen/model/constructor/tree/CgMethodConstructor.kt +++ b/utbot-framework/src/main/kotlin/org/utbot/framework/codegen/model/constructor/tree/CgMethodConstructor.kt @@ -1253,6 +1253,9 @@ internal class CgMethodConstructor(val context: CgContext) : CgContextOwner by c fun createTestMethod(executableId: ExecutableId, execution: UtExecution): CgTestMethod = withTestMethodScope(execution) { val testMethodName = nameGenerator.testMethodNameFor(executableId, execution.testMethodName) + if (execution.testMethodName == null) { + execution.testMethodName = testMethodName + } // TODO: remove this line when SAT-1273 is completed execution.displayName = execution.displayName?.let { "${executableId.name}: $it" } testMethod(testMethodName, execution.displayName) {