An open API service indexing awesome lists of open source software.

https://github.com/franckrasolo/archunit-to-konsist

A comparison of ArchUnit and Konsist for implementing software architecture rules.
https://github.com/franckrasolo/archunit-to-konsist

architectural-patterns architecture-rules archunit archunit-junit5 comparison hexagonal-architecture konsist kotlin ports-and-adapters

Last synced: 8 months ago
JSON representation

A comparison of ArchUnit and Konsist for implementing software architecture rules.

Awesome Lists containing this project

README

          

# Architecture Rules in Kotlin: from ArchUnit to Konsist

[![Kotlin](https://img.shields.io/badge/Kotlin-2.1.0-blue.svg?logo=kotlin&style=flat&labelColor=30373d)](https://github.com/JetBrains/kotlin/releases/tag/v2.1.0)
[![Gradle](https://img.shields.io/badge/Gradle-8.11.1-blue.svg?logo=gradle&logoColor=3cb5c2&style=flat&labelColor=30373d)](https://docs.gradle.org/8.11.1/release-notes.html)
[![ArchUnit](https://img.shields.io/badge/ArchUnit-1.3.0-blue.svg?logo=apachemaven&logoColor=d84531&style=flat&labelColor=30373d)](https://mvnrepository.com/artifact/com.tngtech.archunit/archunit/1.3.0)
[![Konsist](https://img.shields.io/badge/Konsist-0.17.3-blue.svg?logo=apachemaven&logoColor=d84531&style=flat&labelColor=30373d)](https://mvnrepository.com/artifact/com.lemonappdev/konsist/0.17.3)
[![MIT](https://img.shields.io/badge/License-MIT-blue.svg?logo=spdx&style=flat&labelColor=30373d)](https://github.com/franckrasolo/archunit-to-konsist/blob/trunk/LICENSE)

A super simple Kotlin / Gradle project used for a side-by-side comparison of
[ArchUnit](https://www.archunit.org/about) and [Konsist](https://docs.konsist.lemonappdev.com/)
when implementing rules of the _Ports & Adapters_ architectural pattern.

## Documentation

### ArchUnit

- [Why test your architecture?](https://www.archunit.org/motivation)
- [User Guide](https://www.archunit.org/userguide/html/000_Index.html)
- [Architectures](https://www.archunit.org/userguide/html/000_Index.html#_architectures)

### Konsist

- [Architecture Assertion](https://docs.konsist.lemonappdev.com/writing-tests/architecture-assert)
- [Architecture Snippets](https://docs.konsist.lemonappdev.com/inspiration/snippets/architecture-snippets)
- [Clean Architecture Snippets](https://docs.konsist.lemonappdev.com/inspiration/snippets/clean-architecture-snippets)

## Additional Resources

- Design Accelerator: Ports and Adapters Architecture,
[Part 1](https://youtu.be/TC4e0hokDB8) | [Part 2](https://youtu.be/V4nj8MXUv5k) |
[Part 3](https://youtu.be/UpesTQhQhTE) – Vaughn Vernon
- [What's Hexagonal Architecture?](https://medium.com/@luishrsoares/whats-hexagonal-architecture-6da22d4ab600)
_Separating Business Logic From Infrastructure With Ports and Adapters_
- [Hexagonal Architecture Explained](https://www.arhohuttunen.com/hexagonal-architecture/)

[![Medium](https://img.shields.io/badge/Medium-1A1A1A.svg?style=for-the-adge&logo=Medium&logoColor=white)](#additional-resources)

- [ArchUnit vs. Konsist. Why Did We Need Another Kotlin "Linter"? – Igor Wojda](https://proandroiddev.com/archunit-vs-konsist-why-did-we-need-another-linter-972c4ff2622d)
- [ArchUnit vs Konsist in Android (Kotlin-oriented) codebase. A comparison of hidden implementation checks. – Bartek Twaróg](https://medium.com/the-house-of-code/archunit-vs-konsist-in-android-kotlin-oriented-codebase-b72c6c698b0b)
- [Protect Kotlin Project Architecture Using Konsist – Igor Wojda](https://proandroiddev.com/protect-kotlin-project-architecture-using-konsist-3bfbe1ad0eea)
- [Stop Debating in Code Reviews. Start Enforcing with Lint Rules – Stelios Frantzeskakis](https://proandroiddev.com/stop-debating-in-code-reviews-start-enforcing-with-lint-rules-6632c907ea94)

[![YouTube](https://img.shields.io/badge/YouTube-FF0000.svg?style=for-the-badge&logo=YouTube&logoColor=white)](#additional-resources)

- [A Tour Through Konsist with Igor Wojda – Dave Leeds](https://youtu.be/AlYTvzwZOc4)
- [Harmonizing Kotlin codebases with Konsist – Natalia Peterwas, Igor Wojda at KotlinConf 2024](https://youtu.be/3qbKYSI1u1k)
- [Maintain consistency in your Kotlin Codebase with Konsist! – Charfaoui Younes](https://youtu.be/WrGuZ9fgWBg)