This repository provides a partial implementation of the popular board game, Love Letter.
Since the game is played via a command-line interface, GitHub Codespaces is the easiest way to work with this project. To get up and running:
- In the current repository, go to
<> Code > Codespaces > Create codespace on main
. - Wait until the container finishes building.
- After the Codespaces open, wait until you receive the message that the setup is Done and the terminal closes.
- After the setup is done, close the Terminal and open a new window to use any of the pre-installed tools.
Note: Do not forget to push your changes inside Codespaces so that your group partners can access them!
This project uses the following languages, tools, and frameworks:
- Java 17
- Maven
- JUnit 5
- PITest (pitest-junit5-plugin)
- Mockito (v5.6.0)
- EasyMock (v5.2.0)
- Jacoco (v0.8.11)
In Visual Studio Code (VS Code), open the Main.java
file and press the run button in the top right corner.
The application will launch and you can interact with it through the command-line.
Select the class you intend to test and press the run botton next to the class. Optionally, if you want to execute a single test, you can press the run button next to the test case in the class.
You can also run all tests by running the following command in the command-line.
mvn clean compile test
Executing the mvn clean compile test
will create the JaCoCo report. You can access the report in the target/site/jacoco/index.html
folder.
In GitHub Codespaces, you can open the report by opening the index.html
and clicking the Preview icon in the top right ().
If it does not work, press the white square for more browser options (1), select Open in browser
(2), and press Open
, when the confirmation window pops-up.
To execute pitest, execute the following command in the command-line. The command will generate an html report to target/pit-reports/YYYMMDDHHMI
. You can access these html reports similarly to the procedure described for checking the JaCoCo output.
mvn test-compile org.pitest:pitest-maven:mutationCoverage