The JUnit module specifications identify two stereotypes:
-
«JUnit» which is used to stereotype test classes that are created by the JUnit Module.
-
«JUnitDependency» which is used to stereotype dependency links that are established by the JUnit Module between the test classes and the model class they are testing.
Stereotypes declaration
-
Creating the "JUnit" stereotype:
-
Right-click on JUnitProfile to open its contextual menu, then select Modelio Studio –> Stereotype.
-
In the "Create a Stereotype" dialog box.
-
Enter "JUnit" as Label
-
Leave the Id field with the pre-filled value
-
Enter "Class" for the Metaclass
-
Is visible: Checked
-
Owner stereotype: leave blank
-
Description: Used to stereotype test classes.
-
Select a 16x16 icon:
-
Select a 32x32 (or 48x48) icon:
-
-
Creating the "JUnitDependency" stereotype:
-
Right-click on JUnitProfile to open its contextual menu, then select Modelio Studio –> Stereotype.
-
In the "Create a Stereotype" dialog box.
-
Enter "JUnitDependency" as Label
-
Leave the Id field with the pre-filled value
-
Enter "Dependency" for the Metaclass
-
Is visible: Checked
-
Owner stereotype: leave blank
-
Description: This stereotype is used to identify the dependency link between a class of the model and its maching JUnit test class.
-
Select a 16x16 icon:
-
Select a 32x32 (or 48x48) icon:
-
Note:
-
Id value is the name of the stereotype.
-
label value is the name of the stereotype that will appear in Modelio gui and diagrams.