Skip to content

ben-schroeder/random-test-data

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

75 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

random-test-data

Build Status License Maven Central

Random test data for unit tests

Requirements

  • Java >= 8

Artifacts

<dependency>
  <groupId>eu.benschroeder</groupId>
  <artifactId>random-test-data</artifactId>
  <version>0.7</version>
</dependency>

Usage

import eu.benschroeder.testdata.WithRandomTestData;

public class MyUnitTest implements WithRandomTestData {

    @Test
    void testMyMethod() {

        final long anyId = randomLong();
        final String anyName = randomAlphabetic();
        final LocalDateTime anyLocalDateTime = randomPastLocalDateTime();

        ...

    }

}

About

Random test data for unit tests

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published