1 def test(mod
, path
, entity
= None):
3 # ignore anyhting but Firefox
4 if mod
not in ("netwerk", "dom", "toolkit", "security/manager",
5 "browser", "extensions/reporter", "extensions/spellcheck",
6 "other-licenses/branding/firefox",
9 if mod
!= "browser" and mod
!= "extensions/spellcheck":
10 # we only have exceptions for browser and extensions/spellcheck
13 if mod
== "extensions/spellcheck":
16 return not (re
.match(r
"searchplugins\/.+\.xml", path
) or
17 re
.match(r
"chrome\/help\/images\/[A-Za-z-_]+\.png", path
))
18 if mod
== "extensions/spellcheck":
19 # l10n ships en-US dictionary or something, do compare
21 if path
== "defines.inc":
22 return entity
!= "MOZ_LANGPACK_CONTRIBUTORS"
24 if path
!= "chrome/browser-region/region.properties":
25 # only region.properties exceptions remain, compare all others
28 return not (re
.match(r
"browser\.search\.order\.[1-9]", entity
) or
29 re
.match(r
"browser\.contentHandlers\.types\.[0-5]", entity
) or
30 re
.match(r
"gecko\.handlerService\.schemes\.", entity
) or
31 re
.match(r
"gecko\.handlerService\.defaultHandlersVersion", entity
))