1 # This Source Code Form is subject to the terms of the Mozilla Public
2 # License, v. 2.0. If a copy of the MPL was not distributed with this
3 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
5 from __future__
import absolute_import
8 def test(mod
, path
, entity
=None):
11 # ignore anything but Firefox
21 "browser/extensions/formautofill",
22 "browser/extensions/fxmonitor",
23 "browser/extensions/report-site-issue",
24 "extensions/spellcheck",
25 "other-licenses/branding/firefox",
26 "browser/branding/official",
30 if mod
not in ("browser", "extensions/spellcheck"):
31 # we only have exceptions for browser and extensions/spellcheck
34 # the only files to ignore are spell checkers
35 if mod
== "extensions/spellcheck":
38 if mod
== "extensions/spellcheck":
39 # l10n ships en-US dictionary or something, do compare
41 if path
== "defines.inc":
42 return "ignore" if entity
== "MOZ_LANGPACK_CONTRIBUTORS" else "error"
44 if mod
== "browser" and path
== "chrome/browser-region/region.properties":
45 # only region.properties exceptions remain, compare all others
49 re
.match(r
"browser\.contentHandlers\.types\.[0-5]", entity
)
50 or re
.match(r
"gecko\.handlerService\.schemes\.", entity
)
51 or re
.match(r
"gecko\.handlerService\.defaultHandlersVersion", entity
)