Skip to content

Commit f9620e6

Browse files
committed
Fixed checking that the package name starts with java (#1169)
1 parent 767e65c commit f9620e6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

utbot-intellij/src/main/kotlin/org/utbot/intellij/plugin/ui/actions/GenerateTestsAction.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ class GenerateTestsAction : AnAction(), UpdateInBackground {
176176
return true
177177
}
178178

179-
val packageIsIncorrect = this.packageName.startsWith("java")
179+
val packageIsIncorrect = this.packageName.split(".").firstOrNull() == "java"
180180
if (packageIsIncorrect) {
181181
if (withWarnings) InvalidClassNotifier.notify("class ${this.name} located in java.* package")
182182
return true

0 commit comments

Comments
 (0)