|
@ -2,7 +2,7 @@ package de.fd.fh; |
|
|
|
|
|
|
|
|
import org.junit.jupiter.api.Test; |
|
|
import org.junit.jupiter.api.Test; |
|
|
|
|
|
|
|
|
import static org.junit.jupiter.api.Assertions.*; |
|
|
|
|
|
|
|
|
import static org.junit.jupiter.api.Assertions.assertFalse; |
|
|
|
|
|
|
|
|
class FigureBishopTest |
|
|
class FigureBishopTest |
|
|
{ |
|
|
{ |
|
@ -42,10 +42,13 @@ class FigureBishopTest |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@Test |
|
|
@Test |
|
|
void checkValidMovesBishopRight3() |
|
|
|
|
|
|
|
|
void checkInvalidMovesBishopRight3() |
|
|
{ |
|
|
{ |
|
|
Figure f = new FigureBishop(); |
|
|
Figure f = new FigureBishop(); |
|
|
|
|
|
|
|
|
assertFalse(f.moveAllowed(45, 55, field)); |
|
|
|
|
|
|
|
|
int src = Figure.fieldLength * 5 + 5; |
|
|
|
|
|
int dst = src + 10; |
|
|
|
|
|
|
|
|
|
|
|
assertFalse(f.moveAllowed(src, dst, field)); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |