Page MenuHomePhabricator

Improve test data format for XHPAST unit tests
ClosedPublic

Authored by joshuaspence on Nov 17 2015, 11:13 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 29, 1:49 PM
Unknown Object (File)
Wed, Apr 24, 10:16 PM
Unknown Object (File)
Sun, Apr 21, 3:51 PM
Unknown Object (File)
Wed, Apr 17, 2:01 PM
Unknown Object (File)
Tue, Apr 16, 12:40 PM
Unknown Object (File)
Mon, Apr 15, 11:56 PM
Unknown Object (File)
Mon, Apr 15, 11:56 PM
Unknown Object (File)
Mon, Apr 15, 11:54 PM
Subscribers

Details

Summary

Instead of having the input data and expected output stored in separate files, combine all data into a single file format similar to the *.lint-test format.

Test Plan

Ran unit tests.

Diff Detail

Repository
rPHU libphutil
Branch
master
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 8885
Build 10400: Run Core Tests
Build 10399: arc lint + arc unit

Event Timeline

joshuaspence retitled this revision from to Improve test data format for XHPAST unit tests.
joshuaspence updated this object.
joshuaspence edited the test plan for this revision. (Show Details)
joshuaspence added a reviewer: epriestley.
epriestley edited edge metadata.

Oh -- per D14498, these tests still kind of suck because they're almost unreadable. We'd only be slightly worse off by just hashing the tree, I think.

It would be nice to print them in some more human-readable format (mark up the input PHP file somehow to annotate tokens and the parse tree?) instead of dumping the raw JSON.

This revision is now accepted and ready to land.Nov 17 2015, 3:21 PM
This revision was automatically updated to reflect the committed changes.