Index: Source/web/tests/Canvas2DLayerManagerTest.cpp |
diff --git a/Source/core/platform/graphics/Canvas2DLayerManagerTest.cpp b/Source/web/tests/Canvas2DLayerManagerTest.cpp |
similarity index 96% |
rename from Source/core/platform/graphics/Canvas2DLayerManagerTest.cpp |
rename to Source/web/tests/Canvas2DLayerManagerTest.cpp |
index 1d386741480385ba76776e43ffdcd049bb4ba6cf..beb392ef7c1f1605d52a2866f8d7e96a630b9fd9 100644 |
--- a/Source/core/platform/graphics/Canvas2DLayerManagerTest.cpp |
+++ b/Source/web/tests/Canvas2DLayerManagerTest.cpp |
@@ -24,14 +24,14 @@ |
#include "config.h" |
-#include "core/platform/graphics/Canvas2DLayerManager.h" |
+#include "platform/graphics/Canvas2DLayerManager.h" |
#include "SkDevice.h" |
#include "SkSurface.h" |
-#include "core/platform/graphics/GraphicsContext3D.h" |
-#include "core/platform/testing/FakeWebGraphicsContext3D.h" |
+#include "platform/graphics/GraphicsContext3D.h" |
#include "public/platform/Platform.h" |
#include "public/platform/WebThread.h" |
+#include "web/tests/MockWebGraphicsContext3D.h" |
#include <gmock/gmock.h> |
#include <gtest/gtest.h> |
@@ -106,7 +106,7 @@ protected: |
Canvas2DLayerManager& manager = Canvas2DLayerManager::get(); |
manager.init(10, 10); |
{ |
- RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::FakeWebGraphicsContext3D)); |
+ RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::MockWebGraphicsContext3D)); |
RefPtr<SkDeferredCanvas> canvas1(createCanvas(context.get())); |
Canvas2DLayerBridgePtr layer1(adoptRef(new FakeCanvas2DLayerBridge(context, canvas1.release()))); |
EXPECT_EQ((size_t)0, manager.m_bytesAllocated); |
@@ -133,7 +133,7 @@ protected: |
void evictionTest() |
{ |
- RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::FakeWebGraphicsContext3D)); |
+ RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::MockWebGraphicsContext3D)); |
Canvas2DLayerManager& manager = Canvas2DLayerManager::get(); |
manager.init(10, 5); |
RefPtr<SkDeferredCanvas> canvas(createCanvas(context.get())); |
@@ -150,7 +150,7 @@ protected: |
void flushEvictionTest() |
{ |
- RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::FakeWebGraphicsContext3D)); |
+ RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::MockWebGraphicsContext3D)); |
Canvas2DLayerManager& manager = Canvas2DLayerManager::get(); |
manager.init(10, 5); |
RefPtr<SkDeferredCanvas> canvas(createCanvas(context.get())); |
@@ -201,7 +201,7 @@ protected: |
void deferredFrameTest() |
{ |
- RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::FakeWebGraphicsContext3D)); |
+ RefPtr<GraphicsContext3D> context = GraphicsContext3D::createGraphicsContextFromWebContext(adoptPtr(new blink::MockWebGraphicsContext3D)); |
Canvas2DLayerManager::get().init(10, 10); |
RefPtr<SkDeferredCanvas> canvas(createCanvas(context.get())); |
Canvas2DLayerBridgePtr layer(adoptRef(new FakeCanvas2DLayerBridge(context, canvas.release()))); |