mercredi 23 décembre 2020

i have problem on run jumble mutation test

Mutating Assignmment3
Tests: Assignmment3Test
Score: 0% (NO TEST CLASS)
Mutation points = 31
that's what I get when I run my code

public class Assignmment3 {     
public static boolean isEvenNumber(int number){
  
boolean result = false;
  if(number%2==0){
      result = true;}
  return result;
      }
public static void main(String[] args) {
  isEvenNumber(10);
}
}

and that's the test class

        import static org.junit.Assert.*;

import org.junit.Test;
class testAssignment3 {

    @Test
    void test() {
        Assignmment3 meo = new Assignmment3();
        assertEquals(true, meo.isEvenNumber(10));
        assertEquals( false, meo.isEvenNumber(11));
}
}

enter image description here

Aucun commentaire:

Enregistrer un commentaire