First of all, your constructor is not really a constructor:
void DomainTest(int xIn, int yIn, boolean out) {
this.x = xIn;
this.y = yIn;
expectedOut = out;
}
should be:
public DomainTestWithinBorders(int xIn, float yIn, boolean out) {
this.x = xIn;
this.y = yIn;
this.expectedOut = out;
}
(note that correct type of yIn
is float
, not int
):
If you fix this you'll still get the following exception:
java.lang.IllegalArgumentException: argument type mismatch
To fix it, change:
Object[][] values = { { 0, 10.0, false }, { 1, 16.0, false },
{ 17, 17.0, true } };
to:
Object[][] values = { { 0, 10.0f, false }, { 1, 16.0f, false },
{ 17, 17.0f, true } };