Sources for mutation testing workshop with mull.
In addition to setting up a custom development environment, there are two options of a prepared environment: a docker container or a virtual machine setup with vagrant.
Install docker.
Initially create the docker container. This command has to be run just once.
docker build --tag mull-workshop docker/
There is a script to open a shell in the container:
./docker.sh
Use ctrl-d
or exit
to leave the shell.
The shell should open in folder /source
.
Verify the installation by running the roman numeral converter example.
make roman
First install vagrant.
All vagrant commands must be run in folder vm
containting Vagrantfile
.
To start the VM run vagrant up
.
Command vagrant halt
stops the VM.
With vagrant destroy
the VM is shutdown and deleted.
Run vagrant ssh
to open a shell to the development VM.
In the shell you should change to the folder /source
.
cd /source
Verify the installation by running the roman numeral converter example.
make roman
- clang 9
- cmake 3.14 or higher
- mull
- ninja (or make)
In this exercise we want to add some tests to the Gilded Rose inventory system in order to safely refactor before implementing the new feature for conjured items.
Run gilded rose tests in the container:
> make rose
Use mutation testing for guidance in finding test cases.