talira

The programmer-friendly testing framework for Java and the JVM

open sourceEPL-2.0self-hostablefree

JUnit is the standard testing framework for Java and the JVM. JUnit 6, the current generation, requires Java 17 (and Kotlin 2.1 for Kotlin tests) and is built on the JUnit Platform, which launches tests from IDEs and build tools such as Maven and Gradle, and runs several test engines side by side. Its Jupiter engine provides annotations such as @Test, @BeforeEach and @Nested, assertions and assumptions, parameterized and dynamic tests, tags and filtering, parallel execution, timeouts and an extension model, with a guide for migrating from JUnit 4. Artifacts are on Maven Central. Core team members offer commercial support through OpenElements.

Problems it solves

  • write unit tests for my Java code
  • run the same test with many different inputs in Java
  • run my JVM tests from Maven, Gradle and the IDE the same way
  • migrate our old JUnit 4 tests to a modern Java test framework

Features

  • JUnit Platform for launching tests from IDEs and build tools
  • Jupiter programming model with @Test, @Nested and lifecycle annotations
  • assertions and assumptions
  • parameterized and dynamic tests
  • tags and test filtering
  • parallel test execution
  • extension model
  • Kotlin support