| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "extensions/renderer/module_system.h" | 5 #include "extensions/renderer/module_system.h" |
| 6 | 6 |
| 7 #include <stdint.h> |
| 8 |
| 7 #include <utility> | 9 #include <utility> |
| 8 | 10 |
| 9 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
| 10 #include "extensions/renderer/module_system_test.h" | 12 #include "extensions/renderer/module_system_test.h" |
| 11 #include "gin/modules/module_registry.h" | 13 #include "gin/modules/module_registry.h" |
| 12 | 14 |
| 13 namespace extensions { | 15 namespace extensions { |
| 14 | 16 |
| 15 class CounterNatives : public ObjectBackedNativeHandler { | 17 class CounterNatives : public ObjectBackedNativeHandler { |
| 16 public: | 18 public: |
| (...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 497 gin::ModuleRegistry::From(env()->context()->v8_context()) | 499 gin::ModuleRegistry::From(env()->context()->v8_context()) |
| 498 ->AddBuiltinModule( | 500 ->AddBuiltinModule( |
| 499 env()->isolate(), "natives", | 501 env()->isolate(), "natives", |
| 500 other_env->module_system()->NewInstance()); | 502 other_env->module_system()->NewInstance()); |
| 501 other_env->ShutdownModuleSystem(); | 503 other_env->ShutdownModuleSystem(); |
| 502 env()->module_system()->Require("test"); | 504 env()->module_system()->Require("test"); |
| 503 RunResolvedPromises(); | 505 RunResolvedPromises(); |
| 504 } | 506 } |
| 505 | 507 |
| 506 } // namespace extensions | 508 } // namespace extensions |
| OLD | NEW |