For Scala
  • Introduction
  • Quickstart
  • Handbook
  • Quickstart

    Install Stryker4s by cloning the Stryker4s repository

    1 Prepare

    Make sure you have Java installed. Open a terminal / command prompt and change directory to the Stryker4s repository.

    3 Configure

    After cloning the repository, create a stryker4s.conf file in the root of the Stryker4s repository. The configuration below shows all the default options Stryker4s uses. You can edit ones you want to change, or remove the ones that look good for your project. The default configuration will start a command test-runner for sbt. You will have to edit the base-dir to match the codebase you want to mutate. Also, make sure the test-runner is configured with the commands you need to run your unit tests.

    stryker4s {
        log-level=INFO
        mutate=[
            "**/main/scala/**/*.scala"
        ]
        reporters=[
            console
        ]
        test-runner {
            args=test
            command=sbt
            type=commandrunner
        }
    }
    

    3 Let's kill some mutants

    Stryker will run based on the given configuration in the stryker4s.conf. Running stryker now is easy, just do a simple sbt run and Stryker4s will (hopefully) kill the mutants!

    4 Having trouble?

    Having troubles? Try enabling debug logging by adding log-level: 'debug' to your stryker4s.conf. If you are having issues please let us know by reporting an issue or talk to us on Gitter.

    Need help?