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

Unified Diff: runtime/observatory/tests/service/get_isolate_after_out_of_memory_error_test.dart

Issue 2073893002: Removed all analyzer issues from tests (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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
Index: runtime/observatory/tests/service/get_isolate_after_out_of_memory_error_test.dart
diff --git a/runtime/observatory/tests/service/get_isolate_after_async_error_test.dart b/runtime/observatory/tests/service/get_isolate_after_out_of_memory_error_test.dart
similarity index 67%
copy from runtime/observatory/tests/service/get_isolate_after_async_error_test.dart
copy to runtime/observatory/tests/service/get_isolate_after_out_of_memory_error_test.dart
index a0c531d16e0c5114dc22cb86424b2fe75116ed06..24bb08319dd72a024127d04f15970d5bd482e443 100644
--- a/runtime/observatory/tests/service/get_isolate_after_async_error_test.dart
+++ b/runtime/observatory/tests/service/get_isolate_after_out_of_memory_error_test.dart
@@ -7,9 +7,10 @@ import 'package:observatory/service_io.dart';
import 'package:unittest/unittest.dart';
import 'test_helper.dart';
import 'service_test_common.dart';
+import 'dart:math';
-doThrow() async {
- throw "oh no"; // Line 13.
+void goOutOfMemory() {
+ new List(pow(2, 53));
}
var tests = [
@@ -18,11 +19,11 @@ var tests = [
(Isolate isolate) async {
await isolate.reload();
expect(isolate.error, isNotNull);
- expect(isolate.error.message.contains('oh no'), isTrue);
+ expect(isolate.error.message.contains('Out of Memory'), isTrue);
}
];
main(args) async => runIsolateTests(args,
- tests,
- pause_on_exit: true,
- testeeConcurrent: doThrow);
+ tests,
+ pause_on_exit: true,
+ testeeConcurrent: goOutOfMemory);

Powered by Google App Engine
This is Rietveld 408576698