Skip to content

Stabilize ModuleDependency descriptions#1648

Open
DragonFSKY wants to merge 1 commit into
TNG:mainfrom
DragonFSKY:fix-module-dependency-description-order
Open

Stabilize ModuleDependency descriptions#1648
DragonFSKY wants to merge 1 commit into
TNG:mainfrom
DragonFSKY:fix-module-dependency-description-order

Conversation

@DragonFSKY

Copy link
Copy Markdown

Fixes #1630.

This makes ModuleDependency#getDescription() render its underlying class dependencies in their natural Dependency order, instead of relying on the iteration order of the backing set. The collected dependencies are unchanged; only the textual report output is stabilized.

A regression test verifies that the rendered description follows the same sorted dependency order.

Tested with:

./gradlew :archunit:test --tests com.tngtech.archunit.library.modules.ModuleDependencyTest

Sort class dependency descriptions before rendering a module dependency so the text remains stable across set iteration orders.

Issue: TNG#1630

Signed-off-by: Dongliang Xie <dragonfsky@gmail.com>
@DragonFSKY DragonFSKY force-pushed the fix-module-dependency-description-order branch from 40b2f28 to f934965 Compare June 29, 2026 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nondeterministic violation description for ModuleDependency: leads to failing test when used as frozen rule

1 participant