| # Copyright 2014 The Chromium Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/config/ui.gni") |
| import("//sky/engine/config.gni") |
| |
| visibility = [ "//sky/*" ] |
| |
| platform_web_unittest_files = [ |
| "//sky/engine/platform/graphics/BitmapImageTest.cpp", |
| "//sky/engine/platform/graphics/DeferredImageDecoderTest.cpp", |
| "//sky/engine/platform/graphics/ImageDecodingStoreTest.cpp", |
| "//sky/engine/platform/graphics/ImageFrameGeneratorTest.cpp", |
| "//sky/engine/platform/graphics/OpaqueRectTrackingContentLayerDelegateTest.cpp", |
| "//sky/engine/platform/graphics/test/MockImageDecoder.h", |
| "//sky/engine/platform/graphics/test/MockWebGraphicsContext3D.h", |
| "//sky/engine/platform/image-decoders/gif/GIFImageDecoderTest.cpp", |
| "//sky/engine/platform/image-decoders/jpeg/JPEGImageDecoderTest.cpp", |
| ] |
| |
| component("web") { |
| output_name = "sky_web" |
| |
| deps = [ |
| "//sky/engine/core", |
| "//sky/engine/platform", |
| |
| # FIXME: v8_inspector should not depend on core types and be separate |
| # from both web and core. |
| "//sky/engine/v8_inspector", |
| ] |
| |
| configs += [ |
| "//sky/engine:config", |
| "//sky/engine:inside_blink", |
| "//sky/engine:non_test_config", |
| ] |
| |
| sources = [ |
| "AssertMatchingEnums.cpp", |
| "ChromeClientImpl.cpp", |
| "ChromeClientImpl.h", |
| "CompositionUnderlineBuilder.h", |
| "CompositionUnderlineVectorBuilder.cpp", |
| "CompositionUnderlineVectorBuilder.h", |
| "EditorClientImpl.cpp", |
| "EditorClientImpl.h", |
| "FrameLoaderClientImpl.cpp", |
| "FrameLoaderClientImpl.h", |
| "PageWidgetDelegate.cpp", |
| "PageWidgetDelegate.h", |
| "SpellCheckerClientImpl.cpp", |
| "SpellCheckerClientImpl.h", |
| "WebArrayBufferConverter.cpp", |
| "WebArrayBufferView.cpp", |
| "WebCache.cpp", |
| "WebCachedURLRequest.cpp", |
| "WebCustomElement.cpp", |
| "WebDocument.cpp", |
| "WebElement.cpp", |
| "WebFontDescription.cpp", |
| "WebFontImpl.cpp", |
| "WebFontImpl.h", |
| "WebFrame.cpp", |
| "WebGlyphCache.cpp", |
| "WebHitTestResult.cpp", |
| "WebImageCache.cpp", |
| "WebImageDecoder.cpp", |
| "WebInputEvent.cpp", |
| "WebInputEventConversion.cpp", |
| "WebInputEventConversion.h", |
| "Sky.cpp", |
| "WebLeakDetector.cpp", |
| "WebLocalFrameImpl.cpp", |
| "WebLocalFrameImpl.h", |
| "WebNode.cpp", |
| "WebRange.cpp", |
| "WebRuntimeFeatures.cpp", |
| "WebScopedUserGesture.cpp", |
| "WebScriptBindings.cpp", |
| "WebScriptController.cpp", |
| "WebSettingsImpl.cpp", |
| "WebSettingsImpl.h", |
| "WebTextCheckingCompletionImpl.cpp", |
| "WebTextCheckingCompletionImpl.h", |
| "WebTextCheckingResult.cpp", |
| "WebTextInputInfo.cpp", |
| "WebTextRun.cpp", |
| "WebUserGestureIndicator.cpp", |
| "WebUserGestureToken.cpp", |
| "WebViewImpl.cpp", |
| "WebViewImpl.h", |
| "linux/WebFontRendering.cpp", |
| "painting/PaintAggregator.cpp", |
| "painting/PaintAggregator.h", |
| ] |
| |
| if (is_component_build) { |
| deps += [ |
| "//base/test:test_support", |
| "//testing/gmock", |
| "//testing/gtest", |
| "//sky/engine/core:testing", |
| ] |
| |
| configs -= [ "//sky/engine:non_test_config" ] |
| |
| sources += platform_web_unittest_files |
| |
| sources += [ "WebTestingSupport.cpp" ] |
| } |
| } |
| |
| source_set("test_support") { |
| if (!is_component_build) { |
| deps = [ |
| "//skia", |
| "//sky/engine/core:testing", |
| "//sky/engine/wtf", |
| ] |
| |
| sources = [ |
| "WebTestingSupport.cpp", |
| ] |
| |
| configs -= [ "//build/config/compiler:chromium_code" ] |
| configs += [ |
| "//build/config/compiler:no_chromium_code", |
| "//sky/engine:config", |
| ] |
| } |
| } |
| |
| test("sky_unittests") { |
| deps = [ |
| "//base", |
| "//base/test:test_support", |
| "//base:i18n", |
| "//sky/engine/wtf:test_support", |
| "//sky/engine/testing/platform", |
| "//testing/gmock", |
| "//testing/gtest", |
| "//third_party/zlib", |
| "//url", |
| "//v8", |
| ":test_support", |
| ":web", |
| ] |
| |
| sources = [ |
| "tests/RunAllTests.cpp", |
| ] |
| |
| configs += [ "//sky/engine:config" ] |
| |
| if (!is_component_build) { |
| deps += [ "//sky/engine/core" ] |
| |
| configs += [ "//sky/engine:inside_blink" ] |
| |
| sources += platform_web_unittest_files |
| } |
| } |