4b8415dd5a
Previously a separate dart process would be spawned to compile a dart file to JS. This CL internalize it instead, giving a massive speedup. Bug: Change-Id: Ib0c073b1f99ecc0c0531aa83a8299278d90762c8 Reviewed-on: https://dart-review.googlesource.com/29200 Reviewed-by: Dmitry Stefantsov <dmitryas@google.com> Commit-Queue: Jens Johansen <jensj@google.com>
30 lines
788 B
Dart
30 lines
788 B
Dart
import 'package:front_end/src/api_unstable/ddc.dart' as fe;
|
|
import 'package:testing/testing.dart';
|
|
|
|
import 'common.dart';
|
|
import 'ddc_common.dart';
|
|
import 'sourcemaps_ddk_suite.dart' as ddk;
|
|
|
|
Future<ChainContext> createContext(
|
|
Chain suite, Map<String, String> environment) async {
|
|
return new StackTraceContext();
|
|
}
|
|
|
|
class StackTraceContext extends ChainContextWithCleanupHelper
|
|
implements WithCompilerState {
|
|
fe.InitializedCompilerState compilerState;
|
|
|
|
List<Step> _steps;
|
|
|
|
List<Step> get steps {
|
|
return _steps ??= <Step>[
|
|
const Setup(),
|
|
const SetCwdToSdkRoot(),
|
|
new TestStackTrace(
|
|
new ddk.RunDdc(this, false), "ddk.", const ["ddk.", "ddc."]),
|
|
];
|
|
}
|
|
}
|
|
|
|
main(List<String> arguments) => runMe(arguments, createContext, "testing.json");
|