Bug 1831514 - make assignments in .ini test manifests break parsing, r=jmaher

Differential Revision: https://phabricator.services.mozilla.com/D177244
This commit is contained in:
Gijs Kruitbosch 2023-05-05 14:25:38 +00:00
parent 8fdefcd2b3
commit 6f6b4d770d
6 changed files with 40 additions and 12 deletions

View File

@ -25,8 +25,9 @@ environment =
MOZ_PROFILER_STARTUP_ENTRIES=10000000
[../browser_startup_content_mainthreadio.js]
[../browser_startup_mainthreadio.js]
skip-if =
apple_silicon # bug 1707724
socketprocess_networking
os = "win" && bits == 32
skip-if = true # bug 1831406 covers re-enabling this
# skip-if =
# apple_silicon # bug 1707724
# socketprocess_networking
# os = "win" && bits == 32
[../browser_startup_syncIPC.js]

View File

@ -5,7 +5,8 @@ prefs =
telemetry.number_of_site_origin.min_interval=0
[browser_BrowserWindowTracker.js]
skip-if = os = "win" && os_version = "6.1" # bug 1715860
skip-if = true # bug 1831519 covers switching to the 'right' condition below:
# skip-if = os == "win" && os_version == "6.1" # bug 1715860
[browser_ContentSearch.js]
support-files =
contentSearchBadImage.xml
@ -70,4 +71,4 @@ skip-if = os != "win" || (os == "win" && bits == 64) # bug 1456807
skip-if =
(os == "mac") || (os == "linux" && bits == 64 && os_version == "18.04") || (os == "win" && os_version == '10.0' && bits == 64) # Bug 1528429, Bug 1619835
os == 'win' && bits == 32 && debug # Bug 1619835

View File

@ -13,7 +13,8 @@ skip-if = true # Bug 1163311
[test_bug508115.xhtml]
[test_bug514732-2.xhtml]
[test_bug632379.xhtml]
skip-if =
os == 'linux' || (verify && (os == 'win')) # Bug 1207914
os == 'win' && os_version = '10.0' # Bug 1765788
skip-if = true # bug 1831531 covers re-enabling because of the broken condition below.
# skip-if =
# os == 'linux' || (verify && (os == 'win')) # Bug 1207914
# os == 'win' && os_version = '10.0' # Bug 1765788
[test_selection_underline.html]

View File

@ -55,6 +55,7 @@ def read_ini(
fp = io.open(fp, encoding="utf-8")
# read the lines
current_section_name = ""
for (linenum, line) in enumerate(fp.read().splitlines(), start=1):
stripped = line.strip()
@ -97,6 +98,7 @@ def read_ini(
assert default not in section_names
section_names.add(default)
current_section = default_section
current_section_name = "DEFAULT"
continue
if strict:
@ -107,6 +109,7 @@ def read_ini(
section_names.add(section)
current_section = {}
current_section_name = section
sections.append((section, current_section))
continue
@ -122,6 +125,16 @@ def read_ini(
line_indent = len(line) - len(line.lstrip(" "))
if key and line_indent > key_indent:
value = "%s%s%s" % (value, os.linesep, stripped)
if strict:
# make sure the value doesn't contain assignments
if " = " in value:
raise IniParseError(
fp,
linenum,
"Should not assign in {} condition for {}".format(
key, current_section_name
),
)
current_section[key] = value
continue
@ -142,6 +155,15 @@ def read_ini(
if strict:
# make sure this key isn't empty
assert key
# make sure the value doesn't contain assignments
if " = " in value:
raise IniParseError(
fp,
linenum,
"Should not assign in {} condition for {}".format(
key, current_section_name
),
)
current_section[key] = value
break

View File

@ -96,7 +96,8 @@ tags = audiochannel
skip-if = (os == "win" && processor == "aarch64") # aarch64 due to 1536573
[browser_f7_caret_browsing.js]
[browser_findbar.js]
skip-if = os == "linux" && bits == 64 && os_version = "18.04" # Bug 1614739
skip-if = true # a mistake meant the below line was misparsed as just 'true'. Bug 1831517 covers re-enabling.
# skip-if = os == "linux" && bits == 64 && os_version == "18.04" # Bug 1614739
[browser_findbar_disabled_manual.js]
[browser_findbar_marks.js]
[browser_isSynthetic.js]

View File

@ -21,9 +21,11 @@ skip-if = verify && debug && (os == 'mac' || os == 'linux')
[browser_Finder_skip_invisible_and_option.js]
[browser_Finder_vertical_text.js]
[browser_FinderHighlighter.js]
skip-if = debug || os = "linux"
skip-if = true # bug 1831518 covers re-enabling
# skip-if = debug || os == "linux"
[browser_FinderHighlighter2.js]
skip-if = debug || os = "linux"
skip-if = true # bug 1831518 covers re-enabling
# skip-if = debug || os == "linux"
[browser_Geometry.js]
[browser_InlineSpellChecker.js]
[browser_Troubleshoot.js]