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

Side by Side Diff: third_party/WebKit/Source/core/testing/DummyModulator.h

Issue 2697073002: [ES6 modules] Introduce ModuleScriptLoader (Closed)
Patch Set: winfix? Created 3 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef DummyModulator_h
6 #define DummyModulator_h
7
8 #include "bindings/core/v8/ScriptModule.h"
9 #include "core/dom/Modulator.h"
10 #include "platform/heap/Handle.h"
11
12 namespace blink {
13
14 // DummyModulator provides empty Modulator interface implementation w/
15 // NOTREACHED().
16 //
17 // DummyModulator is useful for unit-testing.
18 // Not all module implementation components require full-blown Modulator
19 // implementation. Unit tests can implement a subset of Modulator interface
20 // which is exercised from unit-under-test.
21 class DummyModulator : public GarbageCollectedFinalized<DummyModulator>,
22 public Modulator {
23 USING_GARBAGE_COLLECTED_MIXIN(DummyModulator);
24 DISALLOW_COPY_AND_ASSIGN(DummyModulator);
25
26 public:
27 DummyModulator();
28 virtual ~DummyModulator();
29
30 DECLARE_TRACE();
31
32 ReferrerPolicy referrerPolicy() override;
33 SecurityOrigin* securityOrigin() override;
34 ScriptModule compileModule(const String& script,
35 const String& urlStr) override;
36 };
37
38 } // namespace blink
39
40 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698