build: update the failure message with the correct command (#63219)

Update the failure message for compliance tests to use the correct command for updating the goldens

PR Close #63219
This commit is contained in:
Joey Perrott
2025-08-18 15:01:12 +00:00
committed by Jessica Janiuk
parent bc3798de36
commit b413b62856
3 changed files with 3 additions and 3 deletions
@@ -186,7 +186,7 @@ the generated partial output, we must update the `GOLDEN_PARTIAL.js` file.
This is done by running a specific bazel rule of the form:
```sh
bazel run //packages/compiler-cli/test/compliance/test_cases:<path/to/test_case>.golden.update
bazel run //packages/compiler-cli/test/compliance/test_cases:<path/to/test_case>.golden
```
where to replace `<path/to/test_case>` with the path (relative to `test_cases`) of the directory
@@ -43,7 +43,7 @@ function linkPartials(fileSystem: FileSystem, test: ComplianceTest): CompileResu
throw new Error(
'Golden partial does not exist for this test\n' +
'Try generating it by running:\n' +
`bazel run //packages/compiler-cli/test/compliance/test_cases:${test.relativePath}.golden.update`,
`bazel run //packages/compiler-cli/test/compliance/test_cases:${test.relativePath}.golden`,
);
}
const partialFile = fileSystem.readFile(goldenPartialPath);
@@ -58,7 +58,7 @@ export function checkExpectations(
`The generated file at ${generatedPath} does not exist.\n` +
'Perhaps there is no matching input source file in the TEST_CASES.json file for this test case.\n' +
'Or maybe you need to regenerate the GOLDEN_PARTIAL.js file by running:\n\n' +
` pnpm bazel run //packages/compiler-cli/test/compliance/test_cases:${testPath}.golden.update`,
` pnpm bazel run //packages/compiler-cli/test/compliance/test_cases:${testPath}.golden`,
);
// Clear the stack so that we get a nice error message
error.stack = '';