Skip to content

Commit 818a773

Browse files
committed
fixup! docs: add AGENTS.md guide for AI agents
1 parent bcf0dc1 commit 818a773

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

‎AGENTS.md‎

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,15 @@ This is the source code for the Angular CLI and related build tooling. This guid
3131
import fs from 'node:fs/promises';
3232
import path from 'node:path';
3333

34-
const baseTmpDir = process.env['TEST_TMPDIR'];
35-
assert(baseTmpDir, 'TEST_TMPDIR is not set');
36-
const tempRoot = await fs.mkdtemp(path.join(baseTmpDir, 'SOMETHING'));
34+
describe('...', () => {
35+
let tempRoot: string;
36+
37+
beforeAll(async () => {
38+
const baseTmpDir = process.env['TEST_TMPDIR'];
39+
assert(baseTmpDir, 'TEST_TMPDIR is not set');
40+
tempRoot = await fs.mkdtemp(path.join(baseTmpDir, 'angular-cli-test-'));
41+
});
42+
});
3743
```
3844
- **NEVER** use or fallback to `os.tmpdir()`. Bazel executes tests in hermetic sandboxes and sets `TEST_TMPDIR` to an isolated, sandboxed directory. Using `os.tmpdir()` can cause sandboxing failures, permission errors, or file leakage outside the Bazel sandbox.
3945
- **Imports:**

0 commit comments

Comments
 (0)