Description
If the first statement in MUT used a static field that should be processed concretely and which is not an enum, the engine emits UtError because of NullPointerException produced by environment.state.lastEdge == null.
To Reproduce
Try to generate a test for such a method:
publicstaticvoidconcreteStaticFieldAsFirstStatement() {
System.out.println(0);
}Expected behavior
One test is generated, which does nothing:
@Test@DisplayName("concreteStaticFieldAsFirstStatement: -> PrintStreamPrintln")
publicvoidtestConcreteStaticFieldAsFirstStatement_PrintStreamPrintln() {
HelloWorld.concreteStaticFieldAsFirstStatement();
}
**Actualbehavior**
Oneerrormethodisgenerated:
```javapublicvoidtestConcreteStaticFieldAsFirstStatement_errors() {
// Couldn't generate some tests. List of errors:// // 1 occurrences of:// <Throwable with empty message>
}Environment
Commit c09568f
Java, no mocks.
Additional context
Not applicable
Description
If the first statement in MUT used a static field that should be processed concretely and which is not an enum, the engine emits
UtErrorbecause ofNullPointerExceptionproduced byenvironment.state.lastEdge == null.To Reproduce
Try to generate a test for such a method:
Expected behavior
One test is generated, which does nothing:
Environment
Commit c09568f
Java, no mocks.
Additional context
Not applicable