AssertJ

AssertJ 是一个提供易于使用的富类型断言的库。「AssertJ is a library providing easy to use rich typed assertions」

Github stars Tracking Chart

AssertJ - Fluent Assertions for Java Maven Central Javadocs

CI
Cross-Version
Binary Compatibility
Quality Gate Status

Open in Gitpod

AssertJ provides a rich and intuitive set of strongly-typed assertions to use for unit testing (with JUnit, TestNG or any other test framework).

You can ask questions in stackoverflow (assertj tag) and make suggestions by simply creating an issue.

AssertJ's goals

AssertJ's ambition is to provide a rich and intuitive set of strongly-typed assertions for unit testing.

The idea is that disposal assertions should be specific to the type of the objects we are checking when writing unit tests. If you're checking the value of a String, you use String-specific assertions. Checking the value of a Map? Use Map-specific assertions to easily check the contents of the map.

AssertJ's assertions are super easy to use: just type assertThat(underTest). and use code completion to show you all assertions available.

Assertion missing? Please create an issue to discuss it and even better contribute to the project!

AssertJ is composed of several modules:

Want to contribute?

You are encouraged to contribute any missing useful assertions.

Please read the contributing section and raise a PR!

Overview

Name With Ownerassertj/assertj
Primary LanguageJava
Program languageJava (Language Count: 5)
Platform
License:Apache License 2.0
Release Count72
Last Release Nameassertj-build-3.25.3 (Posted on 2024-02-04 21:52:50)
First Release Nameassertj-core-1.0.0 (Posted on 2013-03-26 09:53:05)
Created At2013-03-14 16:18:49
Pushed At2024-05-16 22:10:17
Last Commit At
Stargazers Count2.5k
Watchers Count71
Fork Count680
Commits Count5.1k
Has Issues Enabled
Issues Count1432
Issue Open Count195
Pull Requests Count1127
Pull Requests Open Count56
Pull Requests Close Count817
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private
To the top