Address PR review comments

- Remove cli-node/src/paths.ts compat layer, migrate all cli-node
  internal usage to import targetPaths from @backstage/cli-common
- Use single-arg overrideTargetPaths('/root') where dir === rootDir
- Scope mockDir to each describe block in bump.test.ts to avoid
  shared state issues with overrideTargetPaths
- Remove unnecessary overrideTargetPaths from plugin-manager.test.ts
- Remove stale findPaths mock from createApp.test.ts
- Use overrideTargetPaths in getWorkspaceRoot.test.ts and cli-node tests

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Patrik Oldsberg
2026-02-23 21:01:27 +01:00
parent ebc01ef04d
commit 641d88cb07
15 changed files with 40 additions and 118 deletions
@@ -42,7 +42,6 @@ jest.mock('@backstage/cli-common', () => {
};
return {
...actual,
findPaths: jest.fn(),
findOwnPaths: () => mockOwnPaths,
};
});