yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #07542
[Branch ~yade-dev/yade/trunk] Rev 2837: - improved section on regression test
------------------------------------------------------------
revno: 2837
committer: Bruno Chareyre <bruno.chareyre@xxxxxxxxxxx>
branch nick: trunk
timestamp: Wed 2011-04-27 15:04:26 +0200
message:
- improved section on regression test
modified:
doc/sphinx/prog.rst
--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk
Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'doc/sphinx/prog.rst'
--- doc/sphinx/prog.rst 2011-04-27 12:42:25 +0000
+++ doc/sphinx/prog.rst 2011-04-27 13:04:26 +0000
@@ -223,8 +223,21 @@
If the compilation is successfull, the buildbot starts unit regression tests and "check tests" (see below) and report the results. If all tests are passed, a new version of the documentation is generated and uploaded to the website in `html <https://www.yade-dem.org/doc/>`__ and `pdf <https://yade-dem.org/doc/Yade.pdf>`__ format. As a consequence, those two links always point to the documentation (the one you are reading now) of the last successfull build, and the delay between commits and documentation updates are very short (minutes).
The buildbot activity and logs can be `browsed online <https://yade-dem.org/buildbot/>`__.
+Regression tests
+----------------
+Yade contains two types of regression tests, some are unit tests while others are testing more complex simulations. Altough both types can be considered regression tests, the usage is that we name the first simply "regression tests", while the latest are called "check tests".
+Both series of tests can ran at yade startup by passing the options "test" or "check" ::
+
+ yade --test
+ yade --check
+
+Unit regression tests
+^^^^^^^^^^^^^^^^^^^^^
+Unit regression tests are testing well the output of individual functors and engines in well defined conditions. They are defined in the folder :ysrc:`py/tests/`.
+The purpose of unit testing is to make sure that the behaviour of the most important classes remains correct during code development. Since they test classes one by one, unit tests can't detect
+
Check tests
------------
+^^^^^^^^^^^
Check tests perform comparisons of simulation results between different versions of yade, as discussed in http://www.mail-archive.com/yade-dev@xxxxxxxxxxxxxxxxxxx/msg05784.html and the whole thread. They differ with regression tests in the sense that they simulate more complex situations and combinations of different engines, and usually don't have a mathematical proof (though there is no restriction on the latest). They compare the values obtained in version N with values obtained in a previous version or any other "expected" results. The reference values must be hardcoded in the script itself or in data files provided with the script. Check tests are based on regular yade scripts, so that users can easily commit their own scripts to trunk in order to get some automatized testing after commits from other developers.
Since the check tests history will be mostly based on standard output generated by "yade --checks", a meaningfull checkTest should include some "print" command telling if something went wrong. If the script itself fails for some reason and can't generate an output, the log will contain "scriptName failure". If the script defines differences on obtained and awaited data, it should print some useful information about the problem and increase the value of global variable resultStatus. After this occurs, the automatic test will stop the execution with error message.