Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
The goal of this tutorial is to present Wodel through a simple example. You can download a zipped version of the project here, or import it in your Eclipse workspace using the File->New->Other->Wodel->New Wodel Project.
In this tutorial you will create a Wodel project, execute some Wodel mutations, and see all the features that Wodel provides to ease mutation development.
This tutorial is designed for mutation developers that are interested on improving the mutation development process.
This tutorial will bring at intermediate level of expertise, where you will be able to use the Wodel IDE to develop a Wodel program, and generate the mutants. From this level, you can take yourself at higher level of expertise, understanding how to use Wodel with different domains.
Before proceeding with this tutorial you should have a good understanding of EMF. If you need more information about EMF, please follow the tutorial available here.
A basic understanding of Eclipse IDE is also required because the examples have been compiled using the Eclipse IDE.
Wodel is available as an Eclipse plugin. Install it by choosing Help → Install New Software…. You will need to add the following software site:
Select and install Wodel.
Creating a new Wodel Project
Now create a new Wodel project by choosing File → New → Other… from the main menu. The dialog offers a couple of different project types. Select New Wodel Project from the category Wodel and continue via Next.
The Wizard will guide you through the new project creation process. You will need to introduce the domain meta-model, in order to let the Wodel engine load it.
Creating a simple Wodel program
A Wodel program describes the interesting mutation operators, and their intended execution schedule. The Wodel IDE provides code completion, and code validation.
Seed models synthesis
A Wodel program is executed on a set of seed models. You can create your own seed models (instances of the domain meta-model), or you can choose to automatically generate them with the seed model synthesizer provided by Wodel. This is useful to assess the validity of the mutation operators. Generate a battery of seed models by right-clicking over the .mutator file in the project explorer, and selecting Wodel... → Generate seed models.
The seed models are stored on the model folder.
Generate the mutants by right-clicking over the .mutator file in the project explorer, and selecting Wodel... → Execute Mutations.
Wodel preferences page
There are some configurable Wodel features. These configurable features are presented on three preferences pages: general, footprints, and seed models generation. Configure these features by clicking over Window in the menu bar, and selecting Preferences → Wodel.
Wodel general preferences page
Activate the registry generation for the applied mutations, and configure which extension shall be executed after the mutants generation. Introduce the maximum number of attempts that will be executed until assuring the mutant is unique, and the maximum number of mutants that will be generated by default. You also need to select the extension Wodel will use to check mutants equivalence.
Wodel footprints preferences page
Configure the footprints options: generate the footprints only for concrete classes. Generate dynamic net mutant footprints, dynamic debug footprints, etc.
Wodel seed models generation preferences page
Configure these several values for the seed models generation.
Show the Wodel footprints view by right-clicking over the Wodel Editor, and selecting each of the provided footprints.
- Meta-model Static Footprint
Shows which elements in the meta-model are affected by the Wodel mutations. These static footprints are divided on two types: explicit footprints, that are the explicit creations (C), modifications (M), and deletions (D) included in the Wodel program; and implicit footprints, that are the resulting creations (IC), modifications (IM) and deletions (ID) in the meta-model when applying the explicit ones.
For instance, the cell for the explicit creation of class State contains 1c 2f, because the program contains one explicit creation of State objects, and two explicit creations of its features.
- Operator Static Footprint
Shows the static footprints by each Wodel mutation operator. These footprints can be used to check the static behaviour of each mutation operator separatedly. These static footprints are also divided on explicit footprints, and implicit footprints.
- Net Dynamic Footprint
Net effect of the program execution calculated by differencing the seed model and the mutant. These footprints show the net operations that had an effect on the generated mutants.
- Debug Dynamic Footprint
Detailed enumeration of applied operators. These debug dynamic footprints show the operations that had an effect on the generated mutants, plus those included in the Wodel program that can't be obtained from the variations on the mutants, but we can get from the applied mutations registry.