Skip to content

Commit c98688a

Browse files
authored
Fixed checking that the package name starts with java (#1171)
1 parent 46b2909 commit c98688a

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)