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

Unified Diff: gin/test/file_runner.cc

Issue 179803007: Refactors parts of gin: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix gin_shell Created 6 years, 10 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
« no previous file with comments | « gin/test/file_runner.h ('k') | mojo/apps/js/bindings/gl/context.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/test/file_runner.cc
diff --git a/gin/test/file_runner.cc b/gin/test/file_runner.cc
index 7b9127368d6591675eb5de8a195b4d6cb6dc38bd..86cb2f34b8e9400c1ef274531e651dbd7f17bbd4 100644
--- a/gin/test/file_runner.cc
+++ b/gin/test/file_runner.cc
@@ -10,6 +10,7 @@
#include "gin/converter.h"
#include "gin/modules/console.h"
#include "gin/modules/module_registry.h"
+#include "gin/public/context_holder.h"
#include "gin/public/isolate_holder.h"
#include "gin/test/gtest.h"
#include "gin/try_catch.h"
@@ -38,7 +39,7 @@ FileRunnerDelegate::FileRunnerDelegate()
FileRunnerDelegate::~FileRunnerDelegate() {
}
-void FileRunnerDelegate::UnhandledException(Runner* runner,
+void FileRunnerDelegate::UnhandledException(ShellRunner* runner,
TryCatch& try_catch) {
ModuleRunnerDelegate::UnhandledException(runner, try_catch);
FAIL() << try_catch.GetStackTrace();
@@ -53,7 +54,7 @@ void RunTestFromFile(const base::FilePath& path, FileRunnerDelegate* delegate,
base::MessageLoop message_loop;
gin::IsolateHolder instance;
- gin::Runner runner(delegate, instance.isolate());
+ gin::ShellRunner runner(delegate, instance.isolate());
{
gin::Runner::Scope scope(&runner);
v8::V8::SetCaptureStackTraceForUncaughtExceptions(true);
@@ -65,8 +66,8 @@ void RunTestFromFile(const base::FilePath& path, FileRunnerDelegate* delegate,
message_loop.Run();
}
- v8::Handle<v8::Value> result = runner.context()->Global()->Get(
- StringToSymbol(runner.isolate(), "result"));
+ v8::Handle<v8::Value> result = runner.global()->Get(
+ StringToSymbol(runner.GetContextHolder()->isolate(), "result"));
EXPECT_EQ("PASS", V8ToString(result));
}
}
« no previous file with comments | « gin/test/file_runner.h ('k') | mojo/apps/js/bindings/gl/context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698