Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Unified Diff: tools/testing/dart/status_reporter.dart

Issue 2919573003: Revert "Revert "Replace the configuration map with a typed object."" (Closed)
Patch Set: Another test fix. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/testing/dart/status_file.dart ('k') | tools/testing/dart/test_configurations.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/status_reporter.dart
diff --git a/tools/testing/dart/status_reporter.dart b/tools/testing/dart/status_reporter.dart
index 69c1a0e7f7bd42252def60ac59989bb6a51620da..b6fd12df8dadd327aae2e6b9bfbd98614a7dde0a 100644
--- a/tools/testing/dart/status_reporter.dart
+++ b/tools/testing/dart/status_reporter.dart
@@ -5,96 +5,85 @@
import 'dart:io';
import 'dart:convert';
-final LINUX_COMBINATIONS = [
- {
- 'runtimes': ['none'],
- 'modes': ['release'],
- 'archs': ['x64'],
- 'compiler': 'dart2analyzer'
- },
- {
- 'runtimes': ['vm'],
- 'modes': ['debug', 'release'],
- 'archs': ['ia32', 'x64', 'simarm', 'simmips'],
- 'compiler': 'none'
- },
- {
- 'runtimes': ['d8', 'jsshell', 'chrome', 'ff'],
- 'modes': ['release'],
- 'archs': ['ia32'],
- 'compiler': 'dart2js'
- },
- {
- 'runtimes': ['dartium'],
- 'modes': ['release', 'debug'],
- 'archs': ['ia32'],
- 'compiler': 'none'
- },
- {
- 'runtimes': ['flutter_engine'],
- 'modes': ['debug', 'release'],
- 'archs': ['x64'],
- 'compiler': 'none'
- },
-];
-
-final MACOS_COMBINATIONS = [
- {
- 'runtimes': ['vm'],
- 'modes': ['debug', 'release'],
- 'archs': ['ia32', 'x64'],
- 'compiler': 'none'
- },
- {
- 'runtimes': ['safari', 'safarimobilesim'],
- 'modes': ['release'],
- 'archs': ['ia32'],
- 'compiler': 'dart2js'
- },
- {
- 'runtimes': ['dartium'],
- 'modes': ['release', 'debug'],
- 'archs': ['ia32'],
- 'compiler': 'none'
- },
-];
-
-final WINDOWS_COMBINATIONS = [
- {
- 'runtimes': ['vm'],
- 'modes': ['debug', 'release'],
- 'archs': ['ia32', 'x64'],
- 'compiler': 'none'
- },
- {
- 'runtimes': ['chrome', 'ff', 'ie11', 'ie10'],
- 'modes': ['release'],
- 'archs': ['ia32'],
- 'compiler': 'dart2js'
- },
- {
- 'runtimes': ['dartium'],
- 'modes': ['release', 'debug'],
- 'archs': ['ia32'],
- 'compiler': 'none'
- },
-];
-
-final COMBINATIONS = {
- 'linux': LINUX_COMBINATIONS,
- 'windows': WINDOWS_COMBINATIONS,
- 'macos': MACOS_COMBINATIONS
+final _combinations = {
+ 'linux': [
+ {
+ 'runtimes': ['none'],
+ 'modes': ['release'],
+ 'archs': ['x64'],
+ 'compiler': 'dart2analyzer'
+ },
+ {
+ 'runtimes': ['vm'],
+ 'modes': ['debug', 'release'],
+ 'archs': ['ia32', 'x64', 'simarm', 'simmips'],
+ 'compiler': 'none'
+ },
+ {
+ 'runtimes': ['d8', 'jsshell', 'chrome', 'ff'],
+ 'modes': ['release'],
+ 'archs': ['ia32'],
+ 'compiler': 'dart2js'
+ },
+ {
+ 'runtimes': ['dartium'],
+ 'modes': ['release', 'debug'],
+ 'archs': ['ia32'],
+ 'compiler': 'none'
+ },
+ {
+ 'runtimes': ['flutter_engine'],
+ 'modes': ['debug', 'release'],
+ 'archs': ['x64'],
+ 'compiler': 'none'
+ },
+ ],
+ 'windows': [
+ {
+ 'runtimes': ['vm'],
+ 'modes': ['debug', 'release'],
+ 'archs': ['ia32', 'x64'],
+ 'compiler': 'none'
+ },
+ {
+ 'runtimes': ['chrome', 'ff', 'ie11', 'ie10'],
+ 'modes': ['release'],
+ 'archs': ['ia32'],
+ 'compiler': 'dart2js'
+ },
+ {
+ 'runtimes': ['dartium'],
+ 'modes': ['release', 'debug'],
+ 'archs': ['ia32'],
+ 'compiler': 'none'
+ },
+ ],
+ 'macos': [
+ {
+ 'runtimes': ['vm'],
+ 'modes': ['debug', 'release'],
+ 'archs': ['ia32', 'x64'],
+ 'compiler': 'none'
+ },
+ {
+ 'runtimes': ['safari', 'safarimobilesim'],
+ 'modes': ['release'],
+ 'archs': ['ia32'],
+ 'compiler': 'dart2js'
+ },
+ {
+ 'runtimes': ['dartium'],
+ 'modes': ['release', 'debug'],
+ 'archs': ['ia32'],
+ 'compiler': 'none'
+ },
+ ]
};
-List<Map> getCombinations() {
- return COMBINATIONS[Platform.operatingSystem];
-}
-
void ensureBuild(Iterable<String> modes, Iterable<String> archs) {
print('Building many platforms. Please be patient.');
var archString = '-a${archs.join(',')}';
-
var modeString = '-m${modes.join(',')}';
var args = [
@@ -102,7 +91,7 @@ void ensureBuild(Iterable<String> modes, Iterable<String> archs) {
modeString,
archString,
'create_sdk',
- // We build runtime to be able to list cc tests
+ // We build runtime to be able to list cc tests.
'runtime'
];
@@ -119,7 +108,7 @@ void ensureBuild(Iterable<String> modes, Iterable<String> archs) {
}
void sanityCheck(String output) {
- LineSplitter splitter = new LineSplitter();
+ var splitter = new LineSplitter();
var lines = splitter.convert(output);
// Looks like this:
// Total: 15556 tests
@@ -139,7 +128,7 @@ void sanityCheck(String output) {
}
void main(List<String> args) {
- var combinations = getCombinations();
+ var combinations = _combinations[Platform.operatingSystem];
var arches = new Set<String>();
var modes = new Set<String>();
@@ -148,9 +137,9 @@ void main(List<String> args) {
arches = ['ia32'].toSet();
modes = ['release'].toSet();
} else {
- for (var combo in combinations) {
- arches.addAll(combo['archs'] as List<String>);
- modes.addAll(combo['modes'] as List<String>);
+ for (var combination in combinations) {
+ arches.addAll(combination['archs'] as List<String>);
+ modes.addAll(combination['modes'] as List<String>);
}
}
« no previous file with comments | « tools/testing/dart/status_file.dart ('k') | tools/testing/dart/test_configurations.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698