Commit 398c37dd authored by yiyaoliu's avatar yiyaoliu Committed by Commit bot

Remove obsolete fieldtrial related code.

BUG=308692

Review URL: https://codereview.chromium.org/513803005

Cr-Commit-Position: refs/heads/master@{#292517}
parent 66e0255c
......@@ -42,9 +42,9 @@ XML below will generate the following five histograms:
<histogram_suffixes_list>
<histogram_suffixes name="BrowserType">
<group name="Chrome"/>
<group name="IE"/>
<group name="Firefox"/>
<suffix name="Chrome"/>
<suffix name="IE"/>
<suffix name="Firefox"/>
<affected-histogram name="HistogramEnum"/>
</histogram_suffixes>
......@@ -307,15 +307,9 @@ def _UpdateHistogramsWithSuffixes(tree, histograms):
"""
have_errors = False
# TODO(yiyaoliu): Remove this part after fieldtrial is not used any more.
if tree.getElementsByTagName('histogram_suffixes'):
histogram_suffix_tag = 'histogram_suffixes'
suffix_tag = 'suffix'
with_tag = 'with-suffix'
else:
histogram_suffix_tag = 'fieldtrial'
suffix_tag = 'group'
with_tag = 'with-group'
histogram_suffix_tag = 'histogram_suffixes'
suffix_tag = 'suffix'
with_tag = 'with-suffix'
# Verify order of histogram_suffixes fields first.
last_name = None
......
......@@ -40,10 +40,6 @@ ALPHABETIZATION_RULES = {
'histogram_suffixes', lambda n: n.attributes['name'].value.lower()),
'histogram_suffixes': ('affected-histogram',
lambda n: n.attributes['name'].value.lower()),
# TODO(yiyaoliu): Remove fieldtrial related pieces when it is not used.
'fieldtrials': ('fieldtrial', lambda n: n.attributes['name'].value.lower()),
'fieldtrial': ('affected-histogram',
lambda n: n.attributes['name'].value.lower()),
}
......
......@@ -20,11 +20,7 @@ ATTRIBUTE_ORDER = {
'int': ['value', 'label'],
'histogram_suffixes': ['name', 'separator', 'ordering'],
'suffix': ['name', 'label'],
# TODO(yiyaoliu): Remove fieldtrial related pieces when it is not used.
'fieldtrial': ['name', 'separator', 'ordering'],
'group': ['name', 'label'],
'affected-histogram': ['name'],
'with-group': ['name'],
'with-suffix': ['name'],
}
......@@ -33,8 +29,6 @@ TAGS_THAT_DONT_INDENT = [
'histogram-configuration',
'histograms',
'histogram_suffixes_list',
# TODO(yiyaoliu): Remove fieldtrial related pieces when it is not used.
'fieldtrials',
'enums'
]
......@@ -43,14 +37,11 @@ TAGS_THAT_DONT_INDENT = [
TAGS_THAT_HAVE_EXTRA_NEWLINE = {
'histogram-configuration': (2, 1, 1),
'histograms': (2, 1, 1),
# TODO(yiyaoliu): Remove fieldtrial related pieces when it is not used.
'fieldtrials': (2, 1, 1),
'histogram': (1, 1, 1),
'histogram_suffixes_list': (2, 1, 1),
'histogram_suffixes': (1, 1, 1),
'enums': (2, 1, 1),
'histogram': (1, 1, 1),
'enum': (1, 1, 1),
'fieldtrial': (1, 1, 1),
}
# Tags that we allow to be squished into a single line for brevity.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment