You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
No tests are generated and C.f() is not even proposed for testing in dialog.
Actual behavior
Plugin shows a dialog with C.f() method. After launching plugin fails with IllegalArgumentException.
Visual proofs (screenshots, logs, images)
java.lang.IllegalArgumentException: Can't retrieve body for <rndpkg.C: int f()>
at org.utbot.engine.ExtensionsKt.jimpleBody(Extensions.kt:114)
at org.utbot.framework.util.SootUtilsKt.jimpleBody(SootUtils.kt:102)
at org.utbot.engine.UtBotSymbolicEngine.<init>(UtBotSymbolicEngine.kt:157)
at org.utbot.framework.plugin.api.TestCaseGenerator.createSymbolicEngine(TestCaseGenerator.kt:278)
at org.utbot.framework.plugin.api.TestCaseGenerator.access$createSymbolicEngine(TestCaseGenerator.kt:51)
at org.utbot.framework.plugin.api.TestCaseGenerator$generate$4$1$1.invokeSuspend(TestCaseGenerator.kt:166)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:274)
at kotlinx.coroutines.BlockingCoroutine.joinBlocking(Builders.kt:84)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(Builders.kt:59)
at kotlinx.coroutines.BuildersKt.runBlocking(Unknown Source)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking$default(Builders.kt:38)
at kotlinx.coroutines.BuildersKt.runBlocking$default(Unknown Source)
at org.utbot.common.ConcurrencyKt.runBlockingWithCancellationPredicate(Concurrency.kt:38)
at org.utbot.framework.plugin.api.TestCaseGenerator$generate$4.invoke(TestCaseGenerator.kt:158)
at org.utbot.framework.plugin.api.TestCaseGenerator$generate$4.invoke(TestCaseGenerator.kt:51)
at org.utbot.common.ConcurrencyKt.runIgnoringCancellationException(Concurrency.kt:47)
at org.utbot.framework.plugin.api.TestCaseGenerator.generate(TestCaseGenerator.kt:157)
at org.utbot.framework.plugin.api.TestCaseGenerator.generate$default(TestCaseGenerator.kt:144)
at org.utbot.intellij.plugin.generator.UtTestsDialogProcessor$createTests$2$1.run(UtTestsDialogProcessor.kt:196)
at com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:935)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcessWithProgressAsync$5(CoreProgressManager.java:442)
at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$3(ProgressRunner.java:235)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:170)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:629)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:581)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:60)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:157)
at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$4(ProgressRunner.java:235)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:834)
Environment
Generate for Java, JUnit5 with Mockito static mocking.
Additional context
Similar problems happen when you try to generate tests for abstract classes that has no implementations.
Description
Currently, if you pass methods from abstract classes to tests generator, you are likely to have an uncaught exception that will ruin test generation
To Reproduce
Launch the plugin on a class C in this example:
Expected behavior
No tests are generated and C.f() is not even proposed for testing in dialog.
Actual behavior
Plugin shows a dialog with C.f() method. After launching plugin fails with
IllegalArgumentException
.Visual proofs (screenshots, logs, images)
Environment
Generate for Java, JUnit5 with Mockito static mocking.
Additional context
Similar problems happen when you try to generate tests for abstract classes that has no implementations.
See also #221.
The text was updated successfully, but these errors were encountered: