TNG/ArchUnit
A Java architecture test library, to specify and assert architecture rules in plain Java observed · 2026-08-28
Health v2 · maintenance only
94/100
- Activity 99
- Release rhythm 84
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-02. Adoption (stars, forks) is never an input.
- gap_med: 48
- age_days: 3421
- days_rel: 29
- days_push: 9
- n_releases_24m: 6
Adoption not part of the score
3810 stars · 347 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-29, confidence not recorded
ArchUnit is a free, extensible Java library for checking the architecture of Java code by analyzing bytecode and asserting rules as plain unit tests. It verifies dependencies between packages, classes, layers, and slices, and detects cyclic dependencies using any Java testing framework.
Use cases
- enforce layered architecture rules in Java tests
- detect cyclic package dependencies
- assert classes only depend on allowed packages
- prevent domain layer from depending on controllers
- run architecture checks in CI as unit tests
- define custom architecture rules with a fluent API
When to choose
- you have a Java/JVM codebase and want automated architecture governance
- you want architecture rules to run as ordinary unit tests in your existing test setup
- you need to enforce layering, slicing, or dependency constraints continuously
When to avoid
- your project is not on the JVM
- you need runtime architecture enforcement rather than build-time tests
- you need full static analysis beyond bytecode-level dependency checks
Facets
library · maturity stable
testing parser developer-tools testing developer-tools jvm cross-platform architecture-tests bytecode-analysis java static-analysis unit-testing architecture
4 sources
- readme: https://github.com/TNG/ArchUnit · fetched 2026-08-28 · 78e6650fb887
- homepage: https://archunit.org · fetched 2026-08-29 · 14fdd65815da
- site_page: https://www.archunit.org/about · fetched 2026-08-29 · 9b4c93df5d4f
- site_page: https://www.archunit.org/getting-started · fetched 2026-08-29 · 3a7445ebdf1c
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| TNG/ArchUnit | main | 94 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem