Skip to content

Organize unit tests into subfolders by topic #244

@vidanovic

Description

@vidanovic

Summary

Unit tests are currently flat within each component's tst/units/ directory (e.g., src/Tarcog/tst/units/). As the number of tests grows, it becomes harder to find and navigate related tests. Tests should be organized into subfolders by topic.

Proposal

Add a second level of organization within each component's test directory. For example, src/Tarcog/tst/units/ could be reorganized into:

src/Tarcog/tst/units/
    deflection/
    vacuum/
    shading/
    venetian/
    gaps/
    system/
    ...

Similar groupings could be applied to other components (SingleLayerOptics, MultiLayerOptics, etc.) as needed.

Notes

  • The CMake glob pattern (tst/units/*.cpp) would need to be updated to tst/units/**/*.cpp or similar to pick up files in subdirectories
  • Existing tests should be moved incrementally — no need to do it all at once
  • The CREATE_TEST_TARGETS_WCE macro may need adjustment for recursive globbing

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions