2 years ago

#76335

test-img

ramkr

Pitest not finding test cases

I'm integrating mutaiton testing using pitest plugin in my intellij here is my plugin for pitest

 <plugin>
                <groupId>org.pitest</groupId>
                <artifactId>pitest-maven</artifactId>
                <version>1.5.2</version>
                <executions>
                    <execution>
                        <phase>test</phase>
                        <goals>
                            <goal>mutationCoverage</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>org.pitest</groupId>
                        <artifactId>pitest-junit5-plugin</artifactId>
                        <version>0.12</version>
                    </dependency>
                </dependencies>
                <configuration>
                    <outputFormats>
                        <outputFormat>XML</outputFormat>
                        <outputFormat>HTML</outputFormat>
                    </outputFormats>
                        <mutationThreshold>0</mutationThreshold>
                        <threads>2</threads>
                        <verbose>true</verbose>
                        <testPlugin>junit</testPlugin>
                    <targetClasses> <!-- target classes was found to be needed when setting up 
     with sonar -->
                        <param>com.mypackage.controller.*</param>
                        <param>com.mypackage.service.*</param>
                    </targetClasses>
                    <targetTests>  <!-- target tests was found to be needed when setting up with 
     sonar -->
                        <param>com.mypackage.rootfolder.*</param> <!-- update to point to the 
     tests that cover your functional code -->
                    </targetTests>
                </configuration>
            </plugin>

i get this ouptut when i run pitest runner in my ide , its not detecting the test classes even though the path i provided in configuration is correct , Please advise

11:45:30 AM PIT >> INFO : Verbose logging is disabled. If you encounter a problem, please enable it before reporting an issue. 11:45:31 AM PIT >> INFO : Sending 14 test classes to minion 11:45:31 AM PIT >> INFO : Sent tests to minion 11:45:31 AM PIT >> INFO : MINION : 11:45:31 AM PIT >> INFO : Checking environment 11:45:32 AM PIT >> INFO : MINION : 11:45:32 AM PIT >> INFO : Found 0 tests 11:45:32 AM PIT >> INFO : MINION : 11:45:32 AM PIT >> INFO : Dependency analysis reduced number of potential tests by 0 11:45:32 AM PIT >> INFO : MINION : 11:45:32 AM PIT >> INFO : 0 tests received 11:45:32 AM PIT >> INFO : Calculated coverage in 1 seconds.

junit5

mutation-testing

pitest

0 Answers

Your Answer

Accepted video resources