Skip to content

Commit

Permalink
fix(bazel): failure messages accidentally printing [Object object]
Browse files Browse the repository at this point in the history
…for commands

Since commands consist of `BazelExpandedValue` objects, the current
failure messages incorrectly print the command.
  • Loading branch information
devversion committed Nov 5, 2021
1 parent 8c73f43 commit baa69aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bazel/integration/test_runner/process_utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export function runCommandInChildProcess(
workingDir: string,
env: NodeJS.ProcessEnv,
): Promise<boolean> {
const humanReadableCommand = `${binary} ${args.join(' ')}`;
const humanReadableCommand = `${binary}${args.length ? ` ${args.join(' ')}` : ''}`;

debug(`Executing command: ${humanReadableCommand} in ${workingDir}`);

Expand Down
2 changes: 1 addition & 1 deletion bazel/integration/test_runner/runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ export class TestRunner {

if (!success) {
throw Error(
`Integration test command: \`${binary} ${evaluatedArgs.join(' ')}\` failed. ` +
`Integration test command: \`${binary.value} ${evaluatedArgs.join(' ')}\` failed. ` +
`See error output above for details.`,
);
}
Expand Down

0 comments on commit baa69aa

Please sign in to comment.