Files
MarkZ 29fe663917 [test] Porting VM enum tests to the hot reload test framework
Change-Id: I8fc17823e5236ab80d89d96c6e3f7d4b82b5b369
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/402762
Reviewed-by: Nate Biggs <natebiggs@google.com>
Commit-Queue: Mark Zhou <markzipan@google.com>
2025-01-03 11:56:07 -08:00

20 lines
594 B
Dart

// Copyright (c) 2025, 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 'package:expect/expect.dart';
import 'package:reload_test/reload_test_utils.dart';
// Adapted from:
// https://github.com/dart-lang/sdk/blob/be2aabd91c67f7f331c49cb74e18fe5e469f04db/runtime/vm/isolate_reload_test.cc#L2015
enum Fruit { Apple, Banana }
var x;
Future<void> main() async {
x = Fruit.Banana;
await hotReload();
Expect.identical(Fruit.Banana, x);
}