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

Side by Side Diff: runtime/vm/unit_test.h

Issue 2186423002: Only reload libraries when they may have been modified. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Code review Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « runtime/vm/snapshot_test.cc ('k') | runtime/vm/unit_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #ifndef VM_UNIT_TEST_H_ 5 #ifndef VM_UNIT_TEST_H_
6 #define VM_UNIT_TEST_H_ 6 #define VM_UNIT_TEST_H_
7 7
8 #include "include/dart_native_api.h" 8 #include "include/dart_native_api.h"
9 9
10 #include "platform/globals.h" 10 #include "platform/globals.h"
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 // Sets |script| to be the source used at next reload. 307 // Sets |script| to be the source used at next reload.
308 static void SetReloadTestScript(const char* script); 308 static void SetReloadTestScript(const char* script);
309 // Initiates the reload. 309 // Initiates the reload.
310 static Dart_Handle TriggerReload(); 310 static Dart_Handle TriggerReload();
311 // Gets the result of a reload. 311 // Gets the result of a reload.
312 static Dart_Handle GetReloadErrorOrRootLibrary(); 312 static Dart_Handle GetReloadErrorOrRootLibrary();
313 313
314 // Helper function which reloads the current isolate using |script|. 314 // Helper function which reloads the current isolate using |script|.
315 static Dart_Handle ReloadTestScript(const char* script); 315 static Dart_Handle ReloadTestScript(const char* script);
316 316
317 // Changes the default importable test lib script.
318 static void SetImportableTestLibScript(const char* source);
319 static void RestoreImportableTestLibScript();
320
317 private: 321 private:
318 static Dart_Isolate CreateIsolate(const uint8_t* buffer, const char* name); 322 static Dart_Isolate CreateIsolate(const uint8_t* buffer, const char* name);
319 323
320 RunEntry* const run_; 324 RunEntry* const run_;
321 }; 325 };
322 326
323 327
324 class TestIsolateScope { 328 class TestIsolateScope {
325 public: 329 public:
326 TestIsolateScope() { 330 TestIsolateScope() {
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
609 } 613 }
610 614
611 private: 615 private:
612 T* flag_; 616 T* flag_;
613 T original_value_; 617 T original_value_;
614 }; 618 };
615 619
616 } // namespace dart 620 } // namespace dart
617 621
618 #endif // VM_UNIT_TEST_H_ 622 #endif // VM_UNIT_TEST_H_
OLDNEW
« no previous file with comments | « runtime/vm/snapshot_test.cc ('k') | runtime/vm/unit_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698