Index: runtime/vm/unit_test.cc |
diff --git a/runtime/vm/unit_test.cc b/runtime/vm/unit_test.cc |
index cb7170f11c9afb2464138e9ff98b99b0e3cfe8b4..a877a1af1923f5bd0d0fa292335f228c17c8a5a3 100644 |
--- a/runtime/vm/unit_test.cc |
+++ b/runtime/vm/unit_test.cc |
@@ -291,16 +291,20 @@ void TestCase::SetReloadTestScript(const char* script) { |
Dart_Handle TestCase::TriggerReload() { |
Isolate* isolate = Isolate::Current(); |
JSONStream js; |
- |
+ bool success = false; |
{ |
TransitionNativeToVM transition(Thread::Current()); |
- isolate->ReloadSources(&js, |
- false, // force_reload |
- true); // dont_delete_reload_context |
+ success = isolate->ReloadSources(&js, |
+ false, // force_reload |
+ true); // dont_delete_reload_context |
fprintf(stderr, "RELOAD REPORT:\n%s\n", js.ToCString()); |
rmacnak
2016/08/03 19:55:25
OS::PrintErr
Cutch
2016/08/03 21:17:19
Acknowledged.
|
} |
- return Dart_FinalizeLoading(false); |
+ if (success) { |
+ return Dart_FinalizeLoading(false); |
+ } else { |
+ return Dart_Null(); |
rmacnak
2016/08/03 19:55:25
Shouldn't this return some kind of error?
Cutch
2016/08/03 21:17:19
In the unit tests we keep the reload context alive
|
+ } |
} |