defined unittests
This commit is contained in:
parent
3708c2c87c
commit
7defeef43b
@ -33,10 +33,23 @@ public class WhiteboxTest {
|
||||
@Test
|
||||
public void defined() {
|
||||
TriangleChecker tc = new TriangleChecker();
|
||||
assertEquals(TriangleType.ISOSCELESS_TRIANGLE, TriangleChecker.checkTriangle(1, 5, 5));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(-1, 5, 3));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(7, 0, 9));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(2, 6, -2));
|
||||
|
||||
assertEquals(TriangleType.EQUILATERAL_TRIANGLE, TriangleChecker.checkTriangle(5, 5, 5));
|
||||
assertEquals(TriangleType.ISOSCELESS_TRIANGLE, TriangleChecker.checkTriangle(2, 2, 3));
|
||||
assertEquals(TriangleType.ISOSCELESS_TRIANGLE, TriangleChecker.checkTriangle(5, 5, 3));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(7, 3, 3));
|
||||
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(2, 2, 5));
|
||||
assertEquals(TriangleType.ISOSCELESS_TRIANGLE, TriangleChecker.checkTriangle(5, 7, 5));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(7, 3, 3));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(2, 1, 5));
|
||||
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(4, 2, 7));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(4, 8, 3));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(10, 4, 3));
|
||||
assertEquals(TriangleType.SCALENE_TRIANGLE, TriangleChecker.checkTriangle(7, 15, 10));
|
||||
assertEquals(TriangleType.NO_TRIANGLE, TriangleChecker.checkTriangle(8, 2, 3));
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user