|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- package praktikum02;
-
- import org.junit.jupiter.api.Test;
-
- import static org.junit.jupiter.api.Assertions.*;
-
- class TriangleCheckerTest {
-
- @Test
- void checkTriangleNormal() {
- assertEquals(TriangleChecker.TriangleType.NORMAL,TriangleChecker.checkTriangle( 10 ,5,6) );
- }
-
- @Test
- void checkTriangleISOSCELES_AB() {
- assertEquals(TriangleChecker.TriangleType.ISOSCELES,TriangleChecker.checkTriangle( 10 ,10,5) );
- }
-
- @Test
- void checkTriangleISOSCELES_BC() {
- assertEquals(TriangleChecker.TriangleType.ISOSCELES,TriangleChecker.checkTriangle( 10 ,5,5) );
- }
-
- @Test
- void checkTriangleISOSCELES_AC() {
- assertEquals(TriangleChecker.TriangleType.ISOSCELES,TriangleChecker.checkTriangle( 10 ,5,10) );
- }
-
- @Test
- void checkTriangle_EQUILATERAL() {
- assertEquals(TriangleChecker.TriangleType.EQUILATERAL,TriangleChecker.checkTriangle( 10 ,10,10) );
- }
-
- @Test
- void checkTriangleNONE_A() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 0 ,10,5) );
- }
-
- @Test
- void checkTriangleNONE_B() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,0,5) );
- }
-
- @Test
- void checkTriangleNONE_C() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,5,0) );
- }
-
- @Test
- void checkTriangleNONE_minusA() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( -2 ,10,5) );
- }
-
- @Test
- void checkTriangleNONE_minusB() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,-2,5) );
- }
-
- @Test
- void checkTriangleNONE_minusC() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,5,-2) );
- }
-
- @Test
- void checkTriangleNONE_AB_C() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,2,13) );
- }
-
- @Test
- void checkTriangleNONE_AC_B() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 10 ,13,2) );
- }
-
- @Test
- void checkTriangleNONE_BC_A() {
- assertEquals(TriangleChecker.TriangleType.NONE,TriangleChecker.checkTriangle( 13 ,10,2) );
- }
- }
|