Skip to content

Commit 86c810f

Browse files
authored
fix: match string template regex incorrect (#42)
* fix: match string template regex incorrect * chore: upgrade version to 1.4.1
1 parent 6e1bd52 commit 86c810f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
pluginGroup = no.eirikb.avatest
55
pluginName = AvaJavaScriptTestRunnerRunConfigurationGenerator
6-
pluginVersion = 1.4.0
6+
pluginVersion = 1.4.1
77
pluginSinceBuild = 202
88
pluginUntilBuild = 999.*
99
# Plugin Verifier integration -> https://github.com/JetBrains/gradle-intellij-plugin#plugin-verifier-dsl

src/main/kotlin/no/eirikb/avatest/utils/getTestNameByClearUnnecessaryString.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ fun getTestNameByClearUnnecessaryString(expression: JSLiteralExpression): String
1818
val paramSourceCode = expression.text
1919

2020
if (paramSourceCode.isNotEmpty() && paramSourceCode.startsWith("`") && paramSourceCode.endsWith("`")) {
21-
val stringTemplateRegex = Regex("\\$\\{.?\\}")
21+
val stringTemplateRegex = Regex("\\\$\\{[^}]+\\}")
2222
return paramSourceCode.replace("`", "").replace(stringTemplateRegex, "*").trim()
2323
}
2424

0 commit comments

Comments
 (0)