Affichage.java

1
package re.forestier.edu.rpg;
2
3
public class Affichage {
4
5
    public static String afficherJoueur(player player) {
6
        final String[] finalString = {"Joueur " + player.Avatar_name + " joué par " + player.playerName};
7
        finalString[0] += "\nNiveau : " + player.retrieveLevel() + " (XP totale : " + player.xp + ")";
8
        finalString[0] += "\n\nCapacités :";
9 1 1. afficherJoueur : removed call to java/util/HashMap::forEach → KILLED
        player.abilities.forEach((name, level) -> {
10
            finalString[0] += "\n   " + name + " : " + level;
11
        });
12
        finalString[0] += "\n\nInventaire :";
13 1 1. afficherJoueur : removed call to java/util/ArrayList::forEach → KILLED
        player.inventory.forEach(item -> {
14
            finalString[0] += "\n   " + item;
15
        });
16
17 1 1. afficherJoueur : replaced return value with "" for re/forestier/edu/rpg/Affichage::afficherJoueur → KILLED
        return finalString[0];
18
    }
19
}

Mutations

9

1.1
Location : afficherJoueur
Killed by : re.forestier.edu.UnitTests.[engine:junit-jupiter]/[class:re.forestier.edu.UnitTests]/[method:testAfficage()]
removed call to java/util/HashMap::forEach → KILLED

13

1.1
Location : afficherJoueur
Killed by : re.forestier.edu.UnitTests.[engine:junit-jupiter]/[class:re.forestier.edu.UnitTests]/[method:testAfficage()]
removed call to java/util/ArrayList::forEach → KILLED

17

1.1
Location : afficherJoueur
Killed by : re.forestier.edu.UnitTests.[engine:junit-jupiter]/[class:re.forestier.edu.UnitTests]/[method:testAfficage()]
replaced return value with "" for re/forestier/edu/rpg/Affichage::afficherJoueur → KILLED

Active mutators

Tests examined


Report generated by PIT 1.15.0