Commit Graph

6 Commits

Author SHA1 Message Date
Mike Pennisi 1303ef0d05 Use "monkeyYaml" in all environments
The "monkeyYaml" parser is intended to serve as a lightweight fallback
to Python's standard YAML parser in contexts where the latter is not
available. Any intentionally-simplified implementation will necessarily
exhibit non-standard behavior for different input, so not all input
accepted by the standard parser will be accepted by "monkeyYaml". If
loaded exclusively in fallback situations, these edge cases can only be
identified (and debugged) in the environments that require the fallback.
This has allowed developers to unknowingly author tests that cause
errors.

Update the test runner to use "monkeyYaml" in all cases, ensuring more
consistent behavior across contexts and precluding this class of
regression.
2015-07-01 14:49:54 -04:00
Domenic Denicola dd243a757c Remove trailing whitespace from the Python 2014-12-01 15:52:19 -05:00
Sam Mikes 9dc29da897 load monkeyYaml without assuming it is on path
use imp to import monkeyYaml locally
make monkeyYaml the backup again
2014-10-24 22:36:03 +01:00
Sam Mikes 4f9cec2fa8 provide fallback parser if YAML not installed
parseTestRecord.py:
- recover from ImportError when YAML not defined
- use monkeyYaml as backup

monkeyYaml.py:
- parser for subset of YAML used in test262 frontmatter

test_monkeyYaml.py:
- unit tests
2014-08-28 12:47:58 +01:00
Sam Mikes c33bf0e043 tools, harness: support new YAML frontmatter
parseTestRecord: add support for YAML frontmatter
parseTestRecord: initial unit test for test record parser
parseTestRecord: refactor for testing

factor old parsing; add YAML parsing

runner: support "includes" from YAML frontmatter

support frontmatter "includes" in python runner
use test.includes if present instead of scanning test code with regex

harness: factor individual functions out into files

tools: handle YAML errors

tolerate missing keys in dictionary (flags, includes)
report filename when empty frontmatter block
new option --list-includes to test262.py

harness: factor helper functions into separate files

sth: remove extra close-paren (syntax error)

test_common: TDD; failing parse of YAML

common: use parseTestRecord (YAML-aware)
2014-07-30 15:39:04 -07:00
Mark Miller 13b63c5486 test262 console runner working! 2011-09-30 08:24:38 -04:00