summaryrefslogtreecommitdiff
path: root/chromium/testing/scripts/finch.gni
blob: 5955c6e802a4044eb20a3646dec3bdd59a6cccba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Copyright 2022 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//testing/test.gni")

template("android_wpt_finch_smoke_tests") {
  assert(defined(invoker.test_case))
  assert(defined(invoker.browser_apk))
  script_test(target_name) {
    script = "//testing/scripts/run_finch_smoke_tests_android.py"
    args = [
      "--test-case",
      invoker.test_case,
      "--browser-apk",
      rebase_path(root_build_dir, root_build_dir) + "/apks/" +
          invoker.browser_apk,
    ]

    if (defined(invoker.webview_provider_apk)) {
      args += [
        "--webview-provider-apk",
        rebase_path(root_build_dir, root_build_dir) + "/apks/" +
            invoker.webview_provider_apk,
      ]
    }

    if (defined(invoker.webview_installer_tool)) {
      args += [
        "--webview-installer-tool",
        rebase_path(invoker.webview_installer_tool, root_build_dir),
      ]
    }

    data = [
      "//build/android/",
      "//build/skia_gold_common/",
      "//testing/scripts/skia_gold_infra",
      "//testing/scripts/variations_smoke_test_data/",
      "//tools/android/",
      "$root_build_dir/pyproto/",
    ]
    data_deps = [
      "//android_webview/proto:aw_variations_seed_proto",
      "//chrome/test/chromedriver:chromedriver($host_toolchain)",
      "//third_party/blink/tools:wpt_tests_android_isolate",
      "//third_party/catapult/devil:devil",
      "//ui/base:goldctl",
    ]

    if (defined(invoker.data)) {
      data += invoker.data
    }

    if (defined(invoker.data_deps)) {
      data_deps += invoker.data_deps
    }
  }
}