Description
Some tests have @utbot.invokes {@link soot.dummy.InvokeDynamic in JavaDocs even though there is no calls to it. This seems happens only for JDK11+ and not happens with JDK 1.8.
To Reproduce
Steps to reproduce the behavior:
- Create new project with JDK11 (for some reason it's not reproducible in UTBot project)
- Copy there
org.utbot.examples.exceptions.ExceptionExamples class from UTBot project.
- Invoke test generation for
IllegalArgumentException createException() method
Expected behavior
JavaDoc for generated tests contains actual information about invoked methods
Actual behavior
@utbot.invoke tag linked to soot method which actually is not called in test or in user code.
Visual proofs (screenshots, logs, images)
/**
* @utbot.classUnderTest {@link ExceptionExamples}
* @utbot.methodUnderTest {@link ExceptionExamples#createException()}
* @utbot.invokes {@link Math#sqrt(double)}
* @utbot.invokes {@link soot.dummy.InvokeDynamic#makeConcatWithConstants(double)}
* @utbot.returnsFrom {@code return new IllegalArgumentException("Here we are: " + Math.sqrt(10));}
*/
@Test
@DisplayName("createException: MathSqrt -> return new IllegalArgumentException(\"Here we are: \" + Math.sqrt(10))")
public void testCreateException_InvokeDynamicMakeConcatWithConstants() throws Exception {
ExceptionExamples exceptionExamples = new ExceptionExamples();
IllegalArgumentException actual = exceptionExamples.createException();
IllegalArgumentException expected = ((IllegalArgumentException) createInstance("java.lang.IllegalArgumentException"));
}
Additional context
That's pre-existing problem, reproducible in 2022.12 release.
Description
Some tests have
@utbot.invokes {@link soot.dummy.InvokeDynamicin JavaDocs even though there is no calls to it. This seems happens only for JDK11+ and not happens with JDK 1.8.To Reproduce
Steps to reproduce the behavior:
org.utbot.examples.exceptions.ExceptionExamplesclass from UTBot project.IllegalArgumentException createException()methodExpected behavior
JavaDoc for generated tests contains actual information about invoked methods
Actual behavior
@utbot.invoketag linked to soot method which actually is not called in test or in user code.Visual proofs (screenshots, logs, images)
Additional context
That's pre-existing problem, reproducible in 2022.12 release.