[ww-devel] PG Tests

Davide P. Cervone dpvc at union.edu
Tue Aug 19 19:29:48 EDT 2014


OK, here are the test files.  I have this directory in the opt/pg directory, but you may have to adjust the locations of directories in the "use lib" statements in MathObjectTests/parserTests.pl to point to your copies of webwork2/lib, pg/lib, and pg/macros.

Each file in the MathObjectTests directory tests one of the MathObject classes.  You can run them individually as

	MathObjectTests/Real.pl

or you can run all the tests via

	MathObejctTests/All.pl

See the individual files for examples of how to provide more tests.  The files don't include all of PG, just the MathObjects code, since that is all that is being tested.  If you want to add tests about the answer checkers, you will need to add "use AnswerHash" to parserTests.pl and use $mo->cmp->evaluate() to call the answer checker.

Anyway, that's what I currently have.  Hope that helps.

Davide

-------------- next part --------------
A non-text attachment was scrubbed...
Name: MathObjectTests.tgz
Type: application/octet-stream
Size: 14005 bytes
Desc: not available
URL: <http://webwork.maa.org/pipermail/webwork-devel/attachments/20140819/e2033c84/attachment.obj>


More information about the webwork-devel mailing list