CodePageLogic.java

1
package io.github.some_example_name;
2
3
import com.badlogic.gdx.math.Vector2;
4
5
public class CodePageLogic {
6
7
    private boolean looking = false;
8
9
    public void handleInteraction(Vector2 playerPos, Vector2 pagePos, boolean ePressed) {
10 1 1. handleInteraction : negated conditional → KILLED
        if (!ePressed) return;
11
12 3 1. handleInteraction : changed conditional boundary → SURVIVED
2. handleInteraction : negated conditional → KILLED
3. handleInteraction : negated conditional → KILLED
        if (!looking && playerPos.dst(pagePos) < 50f) {
13
            looking = true;
14 1 1. handleInteraction : negated conditional → KILLED
        } else if (looking) {
15
            looking = false;
16
        }
17
    }
18
19
    public boolean isLooking() {
20 2 1. isLooking : replaced boolean return with false for io/github/some_example_name/CodePageLogic::isLooking → KILLED
2. isLooking : replaced boolean return with true for io/github/some_example_name/CodePageLogic::isLooking → KILLED
        return looking;
21
    }
22
}
23

Mutations

10

1.1
Location : handleInteraction
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:opensWhenEPressedAndPlayerClose()]
negated conditional → KILLED

12

1.1
Location : handleInteraction
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:opensWhenEPressedAndPlayerClose()]
negated conditional → KILLED

2.2
Location : handleInteraction
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:opensWhenEPressedAndPlayerClose()]
negated conditional → KILLED

3.3
Location : handleInteraction
Killed by : none
changed conditional boundary → SURVIVED

14

1.1
Location : handleInteraction
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:closesWhenEPressedAgain()]
negated conditional → KILLED

20

1.1
Location : isLooking
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:opensWhenEPressedAndPlayerClose()]
replaced boolean return with false for io/github/some_example_name/CodePageLogic::isLooking → KILLED

2.2
Location : isLooking
Killed by : io.github.some_example_name.CodePageLogicTest.[engine:junit-jupiter]/[class:io.github.some_example_name.CodePageLogicTest]/[method:startsNotLooking()]
replaced boolean return with true for io/github/some_example_name/CodePageLogic::isLooking → KILLED

Active mutators

Tests examined


Report generated by PIT 1.15.0