Write a script to help automate the running of PHP OSS Framework unit tests
commit5b3b5880f5942a50308cdb967d5f3faedd75088c
authorJoel Marcey <joelm@fb.com>
Wed, 18 Sep 2013 00:39:06 +0000 (17 17:39 -0700)
committerSara Golemon <sgolemon@fb.com>
Wed, 18 Sep 2013 18:07:20 +0000 (18 11:07 -0700)
tree69021751a66cc91bfbdc819c34ba71457d685573
parent4e5773ad816ce4fc319b4d5be10fb95e8a0cab50
Write a script to help automate the running of PHP OSS Framework unit tests

This is an initial verison of a script that will allow us to unit test all
of the OSS PHP frameworks that we care about for parity. A more detailed
summary is available at the top of the code, but here are some highlights:

- Autodownload of frameworks; not added to our official repo
- Mulit-process test runs
- Full phpunit stats in a file after each run
- Summary file for all tests run showing pass percentage. Appended with latest
  result for multiple test runs of a given framework. Initial inspiration for
  this file was for our MPK TV parity chart population.

Future:

- Integration with our "test/run" infrastructure
- Special case frameworks that don't use PHPUnit
- Enhance the script to allow "diff" stats that specify what changed from the
  previous run of a test of a framework to the current test (beyond pass
  percentage). For example, what tests caused the pass percentage to increase
  or decrease.

New Files for this diff:

- oss_framework_test_script: The script
- phpunit.phar: Used to actually run the phpunit tests for each framework
- composer.phar: Used for installing framework dependencies for phpunit
- sample_multiple_test_config.cfg: A sample configuration file to run multiple, but
  not necessarily all testsi

NOTE: I am only including 3 of the OSS frameworks as part of the code for this diff.
When this diff is accepted, I will send out another diff with the rest added. Having
just 3 makes for easier initial testing.

Another note: I removed the comment that command_line_lib does not support options with
arguments. It does. I am using that functionality in this script.

THANKS TO @ptarjan for process ideas from both running the tests and getting through
the proxy!

Reviewed By: @ptarjan

Differential Revision: D971897
hphp/test/popular_frameworks/composer.phar [new file with mode: 0755]
hphp/test/popular_frameworks/oss_framework_test_script.php [new file with mode: 0644]
hphp/test/popular_frameworks/phpunit.phar [new file with mode: 0755]