blob: aead0714e2a3fc327d3a1a249004af10d977a4c4 [file] [log] [blame]
load("//infra-sk:index.bzl", "karma_test", "sk_demo_page_server", "sk_element", "sk_element_puppeteer_test", "sk_page", "ts_library")
load("//golden/demo-page-assets:index.bzl", "GOLD_DEMO_PAGE_ASSETS")
sk_element(
name = "cluster-page-sk",
sass_deps = ["//infra-sk:elements-sk_scss"],
sass_srcs = ["cluster-page-sk.scss"],
sk_element_deps = [
"//golden/modules/cluster-digests-sk",
"//golden/modules/digest-details-sk",
"//golden/modules/search-controls-sk",
"//infra-sk/modules/paramset-sk",
],
ts_deps = [
"//golden/modules:common_ts_lib",
"//golden/modules:rpc_types_ts_lib",
"//infra-sk/modules/ElementSk:index_ts_lib",
"@npm//common-sk",
"@npm//elements-sk",
"@npm//lit-html",
],
ts_srcs = [
"cluster-page-sk.ts",
"index.ts",
],
visibility = ["//visibility:public"],
)
sk_page(
name = "cluster-page-sk-demo",
html_file = "cluster-page-sk-demo.html",
sk_element_deps = [
"//golden/modules/gold-scaffold-sk",
":cluster-page-sk",
],
ts_deps = [
":test_data_ts_lib",
"//golden/modules:demo_util_ts_lib",
"//golden/modules:rpc_types_ts_lib",
"//golden/modules:settings_ts_lib",
"//golden/modules/digest-details-sk:test_data_ts_lib",
"//golden/modules/last-commit-sk:demo_data_ts_lib",
"@npm//fetch-mock",
],
ts_entry_point = "cluster-page-sk-demo.ts",
)
ts_library(
name = "cluster-page-sk_po_ts_lib",
srcs = ["cluster-page-sk_po.ts"],
visibility = ["//visibility:public"],
deps = [
"//golden/modules/cluster-digests-sk:cluster-digests-sk_po_ts_lib",
"//golden/modules/search-controls-sk:search-controls-sk_po_ts_lib",
"//infra-sk/modules/page_object:page_object_ts_lib",
"//infra-sk/modules/paramset-sk:paramset-sk_po_ts_lib",
],
)
sk_element_puppeteer_test(
name = "cluster-page-sk_puppeteer_test",
src = "cluster-page-sk_puppeteer_test.ts",
sk_demo_page_server = ":demo_page_server",
deps = [
":cluster-page-sk_po_ts_lib",
":test_data_ts_lib",
"//puppeteer-tests:util_ts_lib",
"@npm//@types/chai",
"@npm//chai",
"@npm//puppeteer",
],
)
karma_test(
name = "cluster-page-sk_test",
src = "cluster-page-sk_test.ts",
deps = [
":cluster-page-sk",
":cluster-page-sk_po_ts_lib",
":test_data_ts_lib",
"//golden/modules:settings_ts_lib",
"//infra-sk/modules:test_util_ts_lib",
"@npm//@types/chai",
"@npm//chai",
"@npm//fetch-mock",
],
)
sk_demo_page_server(
name = "demo_page_server",
sk_page = ":cluster-page-sk-demo",
static_assets = GOLD_DEMO_PAGE_ASSETS,
)
ts_library(
name = "test_data_ts_lib",
srcs = ["test_data.ts"],
visibility = ["//visibility:public"],
deps = ["//golden/modules:rpc_types_ts_lib"],
)