diff --git a/dev/bots/run_command.dart b/dev/bots/run_command.dart index 93ce567023..6d3301d373 100644 --- a/dev/bots/run_command.dart +++ b/dev/bots/run_command.dart @@ -90,7 +90,9 @@ Future runCommand(String executable, List arguments, { Duration timeout = _kLongTimeout, bool Function(String) removeLine, }) async { - assert((outputMode == OutputMode.capture) == (output != null)); + assert((outputMode == OutputMode.capture) == (output != null), + 'The output parameter must be non-null with and only with ' + 'OutputMode.capture'); final String commandDescription = '${path.relative(executable, from: workingDirectory)} ${arguments.join(' ')}'; final String relativeWorkingDir = path.relative(workingDirectory); diff --git a/dev/bots/test.dart b/dev/bots/test.dart index 2901fc13d3..c546075ce7 100644 --- a/dev/bots/test.dart +++ b/dev/bots/test.dart @@ -816,8 +816,8 @@ Future _runFlutterTest(String workingDirectory, { Map environment, List tests = const [], }) async { - // Support printing output or capturing it for matching, but not both. - assert(!printOutput || outputChecker == null); + assert(!printOutput || outputChecker == null, + 'Output either can be printed or checked but not both'); final List args = [ 'test',