I'm learning to use Junit. I wrote a method which generates a number strictly less than xX.
I want to test it using Junit. Not sure which assertion to use as the expected is based on xX and I don't see any comparison assertions.
// within the Junit test class
ClassA a = new ClassA();
@Test
void randomTest(){
assertEquals( ? ,a.getValue(5));
}
public int getValue(int xX){
// returns an integer less than xX
return (int) (Math.random() * xX);
}