Bug Report
If I run a no-dependencies test to a folder to whose files there are no dependencies, the test fails as "empty test" although there are files in that directory (they just are not referenced).
Steps to Reproduce
- Set up a directory structure as follows:
- apps (containing some files)
- spa
- src (containing some files without references to the files in "apps")
- test (containing the architecture test below)
- Set up an architecture test for "no dependencies" (see below) in the "spa/test" directory. (The "withName" clause can be left out, the result is the same.) It will fail as "empty test".
- Establish a reference from a file in "spa/src" to a file in "apps". Run the test again -> it will correctly flag the violation.
Environment
- OS: macOS
- Node.js: 24.13.0
- ArchUnitTS: 2.1.63
- Testing Framework: Jest
Code Sample
it('SPA does not depend on old JS code', async () => {
const rule = projectFiles()
.inFolder('src/**')
.shouldNot()
.dependOnFiles()
.inFolder('../apps/**')
.withName('*.{js,jsx,ts,tsx}');
await expect(rule).toPassAsync();
});
Bug Report
If I run a no-dependencies test to a folder to whose files there are no dependencies, the test fails as "empty test" although there are files in that directory (they just are not referenced).
Steps to Reproduce
Environment
Code Sample