We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ff827eb commit e358e0aCopy full SHA for e358e0a
utbot-intellij/src/main/kotlin/org/utbot/intellij/plugin/ui/GenerateTestsDialogWindow.kt
@@ -1033,8 +1033,13 @@ class GenerateTestsDialogWindow(val model: GenerateTestsModel) : DialogWrapper(m
1033
val mockMakerPath = "$entryPath/$MOCKITO_EXTENSIONS_FOLDER/$MOCKITO_MOCKMAKER_FILE_NAME".toPath()
1034
if (!Files.exists(mockMakerPath)) return false
1035
1036
- val fileLines = Files.readAllLines(mockMakerPath)
1037
- fileLines.singleOrNull() == MOCKITO_EXTENSIONS_FILE_CONTENT
+ try {
+ val fileLines = Files.readAllLines(mockMakerPath)
1038
+ fileLines.singleOrNull() == MOCKITO_EXTENSIONS_FILE_CONTENT
1039
+ } catch (e: java.io.IOException) {
1040
+ return false
1041
+ }
1042
+
1043
}
1044
1045
0 commit comments