Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Using multiple @parameters for JUNIT4
- import org.junit.experimental.theories.Theories;
- import org.junit.experimental.theories.Theory;
- import org.junit.experimental.theories.suppliers.TestedOn;
- import org.junit.runner.RunWith;
- @RunWith(Theories.class)
- public class SuppliedByTest {
- @Theory
- public void test1(@TestedOn(ints = { 2, 3, 4, 7, 13, 23, 42 }) int i) {
- System.out.println(i);
- }
- @Theory
- public void test2(@TestedOn(ints = { 6, 3, 4, 7, 13, 23, 42 }) int i) {
- System.out.println(i);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement