Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Tests to achieve 100% mutation coverage #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 32 additions & 3 deletions 4-mutation-pit/triangle/src/test/java/geometry/tritypTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ public void testIsosceles() {
@Test
public void testIsosceles2() {
Assert.assertEquals(trityp.type(10,10,2), 2);
}

}
@Test
public void testNotTriangle1() {
Assert.assertEquals(trityp.type(2,1,3), 4);
Expand Down Expand Up @@ -81,6 +81,35 @@ public void testNotTriangle12() {
int v = trityp.type(1,2,2);
Assert.assertEquals(v, 2);
}


@Test
public void testNotTriangle13() {
Assert.assertEquals(trityp.type(4,8,4), 4);
}

@Test
public void testNotTriangle14() {
Assert.assertEquals(trityp.type(8,4,4), 4);
}

@Test
public void testNotTriangle15() {
Assert.assertEquals(trityp.type(4,4,8), 4);
}

@Test
public void testNotTriangle16() {
Assert.assertEquals(trityp.type(2,3,1), 4);
}

@Test
public void testNotTriangle17() {
Assert.assertEquals(trityp.type(3,2,1), 4);
}

@Test
public void testScalene() {
Assert.assertEquals(trityp.type(10,8,9), 1);
}

}