ZhongXiLu / MuRa

Ranks survived mutants according to their importance

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MuRa

Ranks survived mutants according to their importance.

An online example of the generated report can be found here based on feign.

How to Install

  • The project is built using Maven, so the regular Maven commands apply: mvn install to install the modules.

  • Alternatively, you can download the executable jar on the package page.

  • Finally, you can also use the web interface so you don't have to worry about setting the right values for the configuration and such: MuRa-Web. Skip the steps below if you do so. (recommended)

How to Use

Using PITest

  1. First let PITest run the mutation analysis and generate the reports, make sure there's a directory /target/pit-reports present afterwards.
mvn test -Dfeatures=+EXPORT org.pitest:pitest-maven:mutationCoverage

To include PITest into your project, add the following plugin in your pom.xml:

<plugin>
    <groupId>org.pitest</groupId>
    <artifactId>pitest-maven</artifactId>
    <version>1.4.7</version>
    <configuration>
        <outputFormats>XML</outputFormats>
    </configuration>
    <executions>
        <execution>
            <id>pitest</id>
            <goals>
                <goal>mutationCoverage</goal>
            </goals>
        </execution>
    </executions>
</plugin>
  1. Set up the config file for MuRa. Make sure everything is set properly.

  2. Now everything is ready to call MuRa (after mvn install the executable should be in pitest/target/pitest-1.0.jar):

java -jar pitest-1.1.jar -c config.xml
  1. Afterwards, the report should be generated in /index.html.

  2. If you want to find the optimal weights for your project, checkout this section.

Using another mutation testing tool

Use the com.github.mura.core library to call MuRa and pass the survived mutants of your mutation testing tool. An example of how this is done can be found in the pitest module.

About

Ranks survived mutants according to their importance

License:MIT License


Languages

Language:Java 77.7%Language:Shell 10.5%Language:FreeMarker 8.0%Language:Python 3.7%