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
{{ message }}
Repository navigation
Mutation report names a Spock feature by its generated method name #28
The mutation report of pitestDiff and cribro:pitest-diff names a Spock feature by the name of the method the Spock compiler generates for it, not by the name in the source:
FooSpec.$spock_feature_0_1[2]
for a feature written as def "adds two numbers"(), iteration 2. A reader has to open the compiled spec to learn which feature reached the mutant.
Spock builds the [feature:…] segment of the unique id from the reflected method name (SpockEngineDiscoveryPostProcessor.java:43), and that name is $spock_feature_<depth>_<ordinal> (SpecRewriter.java:343). The test name in PIT's mutations.xml is that id, so cribro has nothing else to print. The rows "Spock feature" and "Spock iteration of a data-driven feature" of PitestSurvivorsTest.platformIds at 6dea6e0 (#26) pin the current output; I have not run a Spock build through pitestDiff.
Expected. A row names a Spock feature by its source name, such as FooSpec."adds two numbers"[2]; the quoting is open. The iteration indices stay as they are.
The source name is in the name of the @FeatureMetadata annotation the Spock compiler puts on the generated method (FeatureMetadata.java:36), so one possible shape, untested, is to read that annotation from the compiled spec class in the test output directory.
Activity