-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
simplify the update of test files #69
Comments
Yeah this is very complex, see also the content of the I guess part of it was a desire to also be able to update the examples in the XML files. Do we have capabilities for that? In any case, in my experience this is not so common so I'd not be worried about loosing it. I thought about cleaning this up at some point but gave up because there were so many levels of indirection :-/. |
The generate_tst_files.g is now obsolete. I have been working on a new version, which is almost ready. When generating examples for the documentation, I noticed that it becomes very tedious to update the examples when output changes due to changes in the package. Also some examples are not suitable as test, and vice versa. So I wanted a system that start from a set of files only containing GAP commands (.g files), convert them into either .tst files or files that can be includes using <#Include ... There is now a file generate_example_files_new in /pkg/forms/examples and a similar file in /pkg/forms/tst. Instead of calling GAP from within a GAP session and generating output using input/output streams, we now generate a shell script. The script will call a number of GAPs, one by one, with the correct input file and which writes output to the correct output file. Afterwards, we convert the output files into .xml files. This seems to work much better now. |
If the new setup simplifies updates then this is in principle fine. If one wants to update example output automatically (and then compare the result with the old contents and decide how to deal with the differences), there are already the following tools.
|
As far as I understand, the test files for the package get updated via the instructions in
tst/generate_tst_files.g
.These instructions themselves would have to be updated, but I think it would be better to use AutoDoc's
extract_examples := true
option (which is available in the AutoDoc version that is required bymakedoc.g
) instead.The text was updated successfully, but these errors were encountered: