See Section 33.4 for a description. However, instead of generating src/asfiles.list and src/Makefile.dep we generate test/tcasfiles.list and test/Makefile.dep.
Note that test/tcasfiles.list is a superset of src/asfiles.list.
The file test/tcasfiles.list is generated via the target tcasfiles.list and given below.
The file test/Makefile.dep generated by tools/dependencies.pl.nw is given below. It is included into test/Makefile.nw. See also Section 33.4.2.
See Section 29.7.2 for the concept of library variants.
A library member depends on the corresponding .as file and the explicitly in the generated file test/Makefile.dep. Furthermore it depends on a .signature.as file, see below.
Note that we must use a static pattern rule here, since only one implicit rule applies and that is given in Section 29.7.2.
We impose a certain structure on the test files so that it is possible to extract automatically the function signatures from the function implementations.
The code below checks for the pattern
testXYZ():() ==
|
where the pattern for XYZ allows any character that can be used in Aldor identifiers. More concretely, we test for the following Perl regular expression.
For example,
testAddition(): () == {
... } |
would be a correct definition.
Note that we include below \s* in front of #(if|else|elseif|endif) and also in front of #include because NOTANGLE might have produced the wrong indentation for the compiler directives, see Section 41.3. Furthermore, note that we copy lines that #include signature files if the filename is not identical to the .signatures.as file that is currently generated.