flutter/dev/devicelab/bin/test_runner.dart
Matan Lurey 5840236ae5
Re-land: "Remove Cocoon from dev/devicelab, keeping Skia perf stats upload" (#165755)
🚫 **Merge after**
https://flutter-review.googlesource.com/c/recipes/+/64300.

---

This reverts commit 0a2d9f56585824689d26a751f3326bf22865ea11.
2025-03-22 21:06:17 +00:00

28 lines
868 B
Dart

// Copyright 2014 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'dart:async';
import 'dart:io';
import 'package:args/command_runner.dart';
import 'package:flutter_devicelab/command/test.dart';
import 'package:flutter_devicelab/command/upload_metrics.dart';
final CommandRunner<void> runner =
CommandRunner<void>('devicelab_runner', 'DeviceLab test runner for recording test results')
..addCommand(TestCommand())
..addCommand(UploadMetricsCommand());
Future<void> main(List<String> rawArgs) async {
unawaited(
runner.run(rawArgs).catchError((dynamic error) {
stderr.writeln('$error\n');
stderr.writeln('Usage:\n');
stderr.writeln(runner.usage);
exit(64); // Exit code 64 indicates a usage error.
}),
);
}