Changeset: 9dfc0c46ca86 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9dfc0c46ca86 Modified Files: documentation/source/developers_handbook.rst Branch: default Log Message:
Add some more documentation about testing diffs (52 lines): diff --git a/documentation/source/developers_handbook.rst b/documentation/source/developers_handbook.rst --- a/documentation/source/developers_handbook.rst +++ b/documentation/source/developers_handbook.rst @@ -25,13 +25,45 @@ are stored in ``.stable.out`` and ``.sta the same directory. For example in the directory ``sql/test/json/Tests`` we find the files: -* ``jsonkeyarray.sql`` -* ``jsonkeyarray.stable.out`` -* ``jsonkeyarray.stable.err`` +* ``jsonkeyarray.Bug-6858.sql`` +* ``jsonkeyarray.Bug-6858.stable.out`` +* ``jsonkeyarray.Bug-6858.stable.err`` + +These three files define the test ``jsonkeyarray.Bug-6858``. + +In any directory with tests you will also find a file named ``All``. This is an +index of all the tests in the directory. If a test is not mentioned in the +``All`` file, it will not run. Running tests ------------- +The `canonical` name of a test is its path relative to the root of the source +tree (``$src_root``), with the ``Tests`` component and the suffix removed. For +instance the above test's canonical name is +``sql/test/json/jsonkeyarray.Bug-6858``. + +In order to run a single test from ``$src_root`` or any of its descendants, use +its canonical name as the argument of ``Mtest.py``:: + + [$src_root] $ Mtest.py sql/test/json/jsonkeyarray.Bug-6858 + +Alternatively, from within the directory where the test is defined you can run +the test by giving the last component of its canonical name as the argument to +``Mtest.py``:: + + [$src_root/sql/test/json/Tests/] $ Mtest.py jsonkeyarray.Bug-6858 + +Another way to run tests is running a number of them together using the +canonical name of a group. For example to run all the tests in the ``json`` +group of the ``sql`` component use:: + + [$src_root] $ Mtest.py sql/test/json/ + +This will run all the tests defined in the file +``$src_root/sql/test/json/Tests/All``. + + Adding a new test ----------------- _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list