ArchUnit / test architecture for Flutter or Dart
Asked Answered
L

1

6

I'm developing an Flutter App using Clean Architecture. Now i'm looking for a library or something else like ArchUnit. To test the architecture and to ensure the correct access of packages.

How do you solve the problem and ensure compliance with the architecture. I would appreciate ideas or alternatives.

Lamplighter answered 11/2, 2021 at 13:36 Comment(2)
Hi have you found any answer to this?Esteresterase
No, unfortunately not :(Lamplighter
L
3

I have not found an Architest equivalent. Another way to ensure correct access to packages is to use a linter like the following

analyzer:
    plugins:
        - import_lint

import_lint:
    rules:
        use_case_rule:
            target_file_path: "/**/use_case/*_use_case.dart"
            not_allow_imports: ["/**/use_case/*_use_case.dart"]
            exclude_imports: ["/**/use_case/base_use_case.dart"]

https://github.com/kawa1214/import-lint

Lubricant answered 14/4, 2022 at 3:42 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.