OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 // TODO(zra): Remove when tests are ready to enable. | |
6 #include "platform/globals.h" | |
7 #if !defined(TARGET_ARCH_ARM64) | |
8 | |
9 #include "platform/assert.h" | 5 #include "platform/assert.h" |
10 #include "vm/globals.h" | 6 #include "vm/globals.h" |
11 #include "vm/isolate.h" | 7 #include "vm/isolate.h" |
12 #include "vm/unit_test.h" | 8 #include "vm/unit_test.h" |
13 | 9 |
14 namespace dart { | 10 namespace dart { |
15 | 11 |
16 UNIT_TEST_CASE(IsolateCurrent) { | 12 UNIT_TEST_CASE(IsolateCurrent) { |
17 Isolate* isolate = Isolate::Init(NULL); | 13 Isolate* isolate = Isolate::Init(NULL); |
18 EXPECT_EQ(isolate, Isolate::Current()); | 14 EXPECT_EQ(isolate, Isolate::Current()); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 EXPECT(!Dart_IsError(result)); | 73 EXPECT(!Dart_IsError(result)); |
78 // Run until all ports to isolate are closed. | 74 // Run until all ports to isolate are closed. |
79 result = Dart_RunLoop(); | 75 result = Dart_RunLoop(); |
80 EXPECT_ERROR(result, "Null callback specified for isolate creation"); | 76 EXPECT_ERROR(result, "Null callback specified for isolate creation"); |
81 EXPECT(Dart_ErrorHasException(result)); | 77 EXPECT(Dart_ErrorHasException(result)); |
82 Dart_Handle exception_result = Dart_ErrorGetException(result); | 78 Dart_Handle exception_result = Dart_ErrorGetException(result); |
83 EXPECT_VALID(exception_result); | 79 EXPECT_VALID(exception_result); |
84 } | 80 } |
85 | 81 |
86 } // namespace dart | 82 } // namespace dart |
87 | |
88 #endif // !defined(TARGET_ARCH_ARM64) | |
OLD | NEW |