mediawiki-extensions-Visual.../tests/parser/README
Adam Wight b234edba88 As much as I have loved writing Makefiles... I've replaced its functionality with package.json, mostly so we can avoid non-node dependencies. This is one of the recommended practices. We should consider moving tests/parser into modules/parser/tests, other node projects keep all module code in one directory.
Explained in the README how to use npm to load the dependencies and run tests.  Too bad about NODE_PATH...

Don't try to find parserTests.txt in assorted places--if it isn't present, fetch from gerrit.  You can symlink from core if you're developing on both parsers, and the fetch script will not overwrite.

Use __dirname in parserTests.js to allow the script to run independent of current working directory.

Change-Id: I4c8b884e91f4fdeae385c7697aff768bdd199dd5
2012-04-04 11:02:58 -07:00

34 lines
999 B
Plaintext

Work in progress. :)
Please see https://www.mediawiki.org/wiki/Future/Parser_development for some
information on how to get started with these tests and the current parser
architecture.
Install dependencies and run tests:
cd tests/parser
make test
== Running parserTests.js ==
For parserTests, you also need MediaWiki's parser test cases (parserTests.txt)
either in a phase3 checkout parallel to extensions (tried by default). You can
also specify a test case file as an argument.
The "make test" target in this directory downloads parserTests.txt and specifies
it as the test case automatically. Of course, you may also run tests manually:
node ./parserTests.js
Several options are available for parserTests:
node ./parserTests.js --help
Enjoy!
== Running roundtrip tests ==
Round-trip tests are not yet ported to the current parser architecture. The
focus so far has been on parserTests and getting the parser architecture in
shape, but we'll get back to round-trip tests eventually.