Closed alisevych closed 1 year ago
@Markoutte Seems to be related to unexpected end/crash of test generation.
When only Booleans and Shorts are left in list
for guava-26.0:
com.google.common.primitives.Booleans
com.google.common.primitives.Shorts
=> they have very good coverage and 100+ test cases in test classes.
May be important:
Stable with @alisevych list
file, no coverage for class Shorts
,
Also:
fuzzingRatio = 0
- always finds some casesShort
. logs contains information that fuzzing stopped on Cancellation for Concrete Execution
Description
Empty test classes for Booleans and Shorts are generated by Contest Estimator
To Reproduce
utbot-junit-contest/src/main/kotlin/org/utbot/contest/ContestEstimator.kt
javaHome
property to full local path to JDK 8timeLimit
in fun main to 120fun main
change:projectFilter = listOf("guava-26.0")
fun main
- make sure to set JRE in Edit Configurations to JDK 8.utbot-junit-contest/build/output/test/guava-26.0
utbot-junit-contest/build/output/test/guava-26.0/com/google/common/primitives
Expected behavior
Tests are supposed to be generated.
Actual behavior
Empty test classes are generated for Booleans and Shorts.
Visual proofs (screenshots, logs, images)
Log record for Shorts: // same for Booleans canceled by timeout = true #methods = 49, #methods started symbolic exploration = 49 #methods with at least one TC = 0 #methods with exceptions = 0 #generated TC = 0 #total coverage = 0/0 #fuzzed coverage = 0/0 #concolic coverage = 0/0
~~~ 3:18:20.600 | INFO | ClassUnderTest[ FQN: com.google.common.primitives.Shorts classfileDir: C:\Users\lWX1182794\UTBotJava\utbot-junit-contest\build\output\unzipped\guava-26.0 testClassSimpleName: ShortsTest generatedTestFile: C:\Users\lWX1182794\UTBotJava\utbot-junit-contest\build\output\test_candidates\guava-26.0\com\google\common\primitives\ShortsTest.java generatedTestsSourcesDir: utbot-junit-contest\build\output\test_candidates\guava-26.0 ] 13:18:20.600 | INFO | Started: class com.google.common.primitives.Shorts 13:18:20.600 | INFO | Started: preparation class class com.google.common.primitives.Shorts: kotlin reflection :: run 13:18:20.611 | INFO | Finished (in 0.011 sec): preparation class class com.google.common.primitives.Shorts: kotlin reflection :: run 13:18:20.611 | INFO | Started: 2nd optional soot initialization 13:18:21.881 | INFO | Finished (in 1.270 sec): 2nd optional soot initialization 13:18:21.904 | DEBUG | ... 13:18:21.904 | INFO | Started: method com.google.common.primitives.Shorts.hashCode 13:18:21.905 | INFO | -- Remaining time budget: 100695 ms, #remaining_methods: 49, budget for method: 2055 ms, solver timeout: 1000 ms, budget for symbolic execution: 1028 ms, budget for concrete execution: 1027 ms, -- 13:18:22.968 | INFO | |> Starting concrete execution for remaining state: com.google.common.primitives.Shorts.hashCode 13:18:24.019 | INFO | (X) Cancelling concrete execution: com.google.common.primitives.Shorts.hashCode 13:18:24.021 | INFO | Finished (in 2.116 sec): method com.google.common.primitives.Shorts.hashCode