Skip to content

livetheoogway/testutils

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TestUtils

A couple of useful simple test utility classes

license

This is a collection of simple test utility classes

Table of Contents

  1. Features
  2. Requirements
  3. Dependencies
  4. Usage

Features

  1. PerformanceEvaluator: Quickly evaluate the performance of your code.
  2. ObjectExtractor: Quickly extract objects from test resource folders

Requirements

  • Java version 17 and above

Dependencies

Add the following dependency to your pom.xml:

<dependency>
    <groupId>com.livetheoogway.commons</groupId>
    <artifactId>testutils</artifactId>
    <version>1.0</version>
</dependency>

Usage

// In order to run an operation 100 times and evaluate its performance, use the PerformanceEvaluator
PerformanceEvaluator performanceEvaluator = new PerformanceEvaluator();
performanceEvaluator.evaluate(100, () -> {
    // your code here
});

// in order to extract an object from a test resource folder, use the ObjectExtractor
ObjectExtractor objectExtractor = new ObjectExtractor();
objectExtractor.extract("path/to/resource/file", SomeClass.class);

About

A couple of useful simple test utility classes

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages