Best practice for looped JUnit test
问题 In a school assignment, I should write blackbox test for a method that returns true for a parameter < 80 and false otherwise. Currently my approach would be for (int i = 0; i < 80; i++) { assertTrue(someMethod(i)); } for (int i = 80; i <= 100; i++) { assertFalse(someMethod(i)); } However, this would require 100 seperate assertions. Is there a best/better practice method? If relevant, I'm using JUnit 5 but could switch to JUnit 4 if required (it's just a school assignment after all). Regards.