summaryrefslogtreecommitdiff
path: root/chromium/tools/metrics/BUILD.gn
blob: 3de6d261091a749e20e908d3839b29b018e483c3 (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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
# Copyright 2017 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.

action("histograms_xml") {
  script = "histograms/merge_xml.py"
  sources = [
    "histograms/enums.xml",
    "histograms/histograms.xml",
  ]
  output = "$root_out_dir/histograms.xml"
  outputs = [
    output,
  ]
  args = rebase_path(sources, root_build_dir) + [
           "--output",
           rebase_path(output, root_build_dir),
         ]
}

copy("actions_xml") {
  sources = [
    "actions/actions.xml",
  ]
  outputs = [
    "$root_out_dir/actions.xml",
  ]
}

copy("rappor_xml") {
  sources = [
    "rappor/rappor.xml",
  ]
  outputs = [
    "$root_out_dir/rappor.xml",
  ]
}

copy("ukm_xml") {
  sources = [
    "ukm/ukm.xml",
  ]
  outputs = [
    "$root_out_dir/ukm.xml",
  ]
}

group("metrics_metadata") {
  deps = [
    ":actions_xml",
    ":histograms_xml",
    ":rappor_xml",
    ":ukm_xml",
  ]
}

# This group defines the isolate files needed to run metrics_python_tests.py on
# on bots. This also tells the build system when the tests should be re-run -
# when one of the dependent files changes.
#
# When adding new entries to this test suite, you can test things locally with
# isolation using the following command:
#
#  tools/mb/mb.py run out/gn metrics_python_tests -- \
#    --isolated-script-test-output=/tmp/output.json
#
group("metrics_python_tests") {
  data = [
    # The run_isolated_script_test.py script and its dependencies.
    "//testing/scripts/run_isolated_script_test.py",
    "//testing/scripts/common.py",
    "//testing/xvfb.py",
    "//testing/test_env.py",
    "//third_party/catapult/third_party/typ/",

    # Scripts we depend on. Their unit tests are also included.
    "//tools/json_comment_eater/json_comment_eater.py",
    "//tools/json_comment_eater/json_comment_eater_test.py",
    "//tools/json_comment_eater/everything.json",
    "//tools/json_comment_eater/everything_expected.json",
    "//tools/json_to_struct/element_generator.py",
    "//tools/json_to_struct/element_generator_test.py",
    "//tools/json_to_struct/json_to_struct.py",
    "//tools/json_to_struct/struct_generator.py",
    "//tools/json_to_struct/struct_generator_test.py",

    # The metrics_python_tests.py runner and its dependencies.
    "//tools/metrics/metrics_python_tests.py",

    "//tools/metrics/actions/action_utils.py",
    "//tools/metrics/actions/actions_print_style.py",
    "//tools/metrics/actions/extract_actions.py",
    "//tools/metrics/actions/extract_actions_test.py",

    "//tools/metrics/common/diff_util.py",
    "//tools/metrics/common/models.py",
    "//tools/metrics/common/path_util.py",
    "//tools/metrics/common/presubmit_util.py",
    "//tools/metrics/common/pretty_print_xml.py",
    "//tools/metrics/common/etree_util.py",

    "//tools/metrics/histograms/extract_histograms.py",
    "//tools/metrics/histograms/generate_expired_histograms_array.py",
    "//tools/metrics/histograms/generate_expired_histograms_array_unittest.py",
    "//tools/metrics/histograms/histograms_print_style.py",
    "//tools/metrics/histograms/merge_xml.py",
    "//tools/metrics/histograms/pretty_print.py",
    "//tools/metrics/histograms/pretty_print_test.py",

    "//tools/metrics/rappor/rappor_model.py",
    "//tools/metrics/rappor/rappor_model_test.py",

    "//tools/metrics/ukm/ukm.xml",
    "//tools/metrics/ukm/codegen.py",
    "//tools/metrics/ukm/builders_template.py",
    "//tools/metrics/ukm/decode_template.py",
    "//tools/metrics/ukm/gen_builders.py",
    "//tools/metrics/ukm/gen_builders_test.py",
    "//tools/metrics/ukm/ukm_model.py",
    "//tools/metrics/ukm/ukm_model_test.py",
    "//tools/metrics/ukm/xml_validations.py",
    "//tools/metrics/ukm/xml_validations_test.py",

    "//tools/python/google/path_utils.py",

    "//tools/variations/fieldtrial_to_struct_unittest.py",
    "//tools/variations/fieldtrial_to_struct.py",
    "//tools/variations/fieldtrial_util_unittest.py",
    "//tools/variations/fieldtrial_util.py",
    "//tools/variations/split_variations_cmd_unittest.py",
    "//tools/variations/split_variations_cmd.py",
    "//tools/variations/unittest_data/expected_output.cc",
    "//tools/variations/unittest_data/expected_output.h",
    "//tools/variations/unittest_data/test_config.json",
    "//tools/variations/unittest_data/variations_cmd.txt",
    "//components/variations/field_trial_config/field_trial_testing_config_schema.json",
    "//components/variations/service/generate_ui_string_overrider.py",
    "//components/variations/service/generate_ui_string_overrider_unittest.py",
  ]
}