Add tests for cli-errors and fix one bug

Tests were added with copilot, and uncovered a bug where one of the
regexps looking for `[autobuild]` was not escaping the square brackets.
This commit is contained in:
Paolo Tranquilli
2025-08-07 09:55:59 +02:00
parent 7b33b610d4
commit 1cfc0c2621
6 changed files with 619 additions and 3 deletions

View File

@@ -171,7 +171,7 @@ export const cliErrorsConfig: Record<
},
[CliConfigErrorCategory.GradleBuildFailed]: {
cliErrorMessageCandidates: [
new RegExp("[autobuild] FAILURE: Build failed with an exception."),
new RegExp("\\[autobuild\\] FAILURE: Build failed with an exception."),
],
},
// Version of CodeQL CLI is incompatible with this version of the CodeQL Action