mirror of https://github.com/CGAL/cgal
the testsuite are really submitted to the SVN repository - fixed documentation of testsuite in README |
||
|---|---|---|
| .. | ||
| Maple | ||
| data | ||
| testsuite-data | ||
| README | ||
| create-testsuite | ||
| test_MPS.C | ||
| test_MPS.cin | ||
| test_solver.C | ||
| test_solver.cin | ||
| test_suite_QP_solver.C | ||
| test_suite_QP_solver.cin | ||
README
OVERVIEW This file explains the structure of the testsuite directory of package QP_solver. THE CGAL TESTSUITE PROCESS The CGAL testsuite calls the QP_solver testsuite via ./test_suite_QPE_solver < test_suite_QPE_solver.cin ./test_solver < test_solver.cin The latter files contain the filenames of individual test cases to be solved (so test_suite_QPE_solver.cin and test_solver.cin do NOT contain the test data itself). The executables ./test_suite_QPE_solver and ./test_solver read these filenames (and some further options specifying what pricing strategy etc. is to be used for each test case) and processes them one after the other. All these test data files are contained in the directory data/ and end in ".data_f", ".data_i", or ".data_r" in case of ./test_suite_QPE_solver, and in the directory testsuite-data/ and end in ".mps" in case of ./test_solver, respectively. WHERE THE .data_* AND .mps FILES COME FROM The above .data_* and .mps files could be written by hand, but we generate them from Maple worksheets. (This makes it easier to play around with the data and to verify results in Maple if need be.) Thus, every .data_* file is in fact produced by some Maple worksheet and all these Maple worksheets are stored in the directory Maple/data/ and end in ".mema". (For most .mps files, this is also true, but the directories testsuite-data/additional-for-cgal testsuite-data/additional-not-for-cgal contain additional .mps files that are NOT generated from mema's.) If you open one of these mema-files, you can see that this is a simple ASCII file consisting of Maple commands. Executing a mema-file via maple mema-file-name creates the corresponding .data_* and .mps files in the data/ directory. Notice that every .data_* file has a corresponding mema-file and that some mema-files produce multiple .data_* files. (The same holds for all .mps files except the ones in the above "additional-..." directories.) THE CGAL TESTSUITE AND THE COMPLETE TESTSUITE In order to create the .data_* and .mps files from the mema-files, you can use the script ./create-testsuite which you either invoke as ./create-testsuite CGAL <verbosity (i.e., 0, 1, 2, 3, 4, or 5)> or as ./create-testsuite all <verbosity (i.e., 0, 1, 2, 3, 4, or 5)> We make this distinction because we have a very large testsuite and do not want to put all tests contained in it into the CGAL testsuite (it would take hours to run this testsuite). Thus, the former of the above commands only converts a small subset of all the mema-files to .data_* files and produces the files test_suide_QPE_solver.cin and test_solver.cin (see above) with the corresponding commands to execute these tests. (In case of test_solver.cin, the files from testsuite-data/additional-for-cgal are always included, and, in addition if ./create-testsuite is called with argument "all", also the files from testsuite-data/additional-not-for-cgal are included.) If you want that the commands "./test_solver < test_solver.cin" and "./test_suite_QPE_solver < test_suite_QPE_solver.cin" execute ALL tests contained in our testsuite then you need to do a "./create-testsuite all". How does the ./create-testsuite script know which test case is part of the CGAL testsuite (i.e., which test case to convert if you pass "CGAL" as its argument)? The script looks into the mema-file and if there is a command is_part_of_CGAL_testsuite:= true in it, it considers the test as part of the CGAL testsuite. Observe here that all .data_* files originating from such mema-files NEED TO BE PRESENT IN THE REPOSITORY (the script ./create-testsuite will warn you if such a file is missing in the repository). VIEWING mema-FILES IN MAPLE If you want to play around with a specific mema-file in Maple then you can use the script Maple/data2mw which converts a mema-file to a "pretty" Maple worksheet. Call the script ./generate-worksheets which converts all mema-files in Maple/data/ to nicely formatted Maple worksheets (which you can then find in Maple/). (Internally, ./generate-worksheets uses the program data2mw.C to do the conversion.)