dart-sdk/tests/macro_build/cfe_sdk_cli_test.dart
David Morgan c2004efd47 [macros] Add macro build tests.
These are a new type of test that runs with the SDK under test against what
looks like an external package; they start by running "pub get" then run SDK
build commands to build the package, and check that macros applied correctly.

Add tests for various builds that already pass, plus one that doesn't:
cfe_sdk_cli_test fails because it was switched to run from an AOT snapshot
and that doesn't support macros yet.

Change-Id: Ic801cb61bd414d4876566452e01dd8c8203e9013
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/353100
Reviewed-by: Jake Macdonald <jakemac@google.com>
Reviewed-by: William Hesse <whesse@google.com>
Commit-Queue: Morgan :) <davidmorgan@google.com>
2024-03-06 12:31:37 +00:00

17 lines
457 B
Dart

// Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
import 'tester/tester.dart';
void main() {
testMacroBuild([
r'$DART pub get',
r'$DART compile kernel '
'--enable-experiment=macros '
'-o out.kernel '
'test/main.dart',
r'$DART run out.kernel',
]);
}