Skip to content

Java Test Helpers (currently random generators)

Notifications You must be signed in to change notification settings

rynr/test-helper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

test-helper

I like using random values for tests. So I wrote the methods for random values quite often. Now i started this library to not write it again and again.

example

@Test
public void testSomethingWithARandomValue() {
    int randomIntFullIntegerRange = RandomValues.randomInt();
    int randomPositiveIntWithMax = RandomValues.randomInt(15);
    ExampleEnum randomEnumValue = RandomValues.randomEnum(ExampleEnum.class);
    // ...
}

links