HomePhabricator

Add unit test scaffolding for XHPAST/PHPAST

Description

Add unit test scaffolding for XHPAST/PHPAST

Summary:
Ref T4334. Allows us to build tests against this so we can accomplish goals described in T4334 with greater confidence.

This allows three types of tests to be defined:

  • pass: Input is expected to parse into a specific tree.
  • fail-syntax: Input is expected to fail with a syntax error.
  • fail-parse: Input is expected to parse the wrong tree.

The latter two test types allow us to write passing tests of broken/bad behavior while keeping it clear which tests are passing-and-good and which are passing-but-broken.

Test Plan: Ran unit tests.

Reviewers: btrahan, Firehed

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4334

Differential Revision: https://secure.phabricator.com/D8025

Details

Provenance
epriestleyAuthored on
epriestleyPushed on Jan 21 2014, 10:31 PM
Reviewer
btrahan
Differential Revision
D8025: Add unit test scaffolding for XHPAST/PHPAST
Parents
rPHU6ee25dfe7db5: Make directory fixture script slightly more modern and usable
Branches
Unknown
Tags
Unknown
Tasks
T4334: Support PHP5.4+ syntax in XHPAST

Event Timeline