| # Copyright 2015 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("//chrome/common/features.gni") |
| import("//mojo/public/tools/bindings/mojom.gni") |
| import("//third_party/closure_compiler/compile_js.gni") |
| import("//tools/grit/grit_rule.gni") |
| |
| grit("webui_test_resources") { |
| source = "webui_test_resources.grd" |
| defines = chrome_grit_defines |
| outputs = [ |
| "test/data/grit/webui_test_resources.h", |
| "webui_test_resources.pak", |
| ] |
| |
| deps = [ ":web_ui_test_bindings_js" ] |
| |
| grit_flags = [ |
| "-E", |
| "root_gen_dir=" + rebase_path(root_gen_dir, root_build_dir), |
| ] |
| output_dir = "$root_gen_dir/chrome" |
| } |
| |
| mojom("web_ui_test_bindings") { |
| sources = [ |
| "webui/mojo/foobar.mojom", |
| "webui/web_ui_test.mojom", |
| ] |
| } |
| |
| js_type_check("closure_compile") { |
| deps = [ ":test_api_js" ] |
| } |
| |
| js_library("test_api_js") { |
| sources = [ "webui/test_api.js" ] |
| externs_list = [ |
| "webui/mock4js_externs.js", |
| "//third_party/chaijs/externs/chai-3.5.js", |
| "//ui/webui/resources/js/dom_automation_controller.js", |
| ] |
| deps = [ ":web_ui_test_bindings_js_library_for_compile" ] |
| } |