Functional test overview
Functional tests include SQL scripts and shell scripts that execute the SQL scripts and determine the results. The shell scripts build test tables in a database, run the SQL test scripts, and then drop the test tables from the database.
You can create custom shell scripts to run additional tests or initialization scripts. The generated scripts include calls to your custom scripts.
Shell scripts execute SQL scripts by using DB-Access. The results from the SQL statements are saved in .log files. When you first run functional tests, you must inspect the .log files and, if the results are correct, use the shell scripts to copy them to .req files.
When you execute functional tests after saving .req files,
the shell script uses the UNIX™ diff command
to compare the .log files to the .req files.
The script prints the following messages:
- test passed message if the .log and .req files match
- test failed message if the files do not match
- status unknown message when a .req file does not yet exist
Important: There are minor formatting differences
between the UNIX and Windows™ versions of DB-Acess
that can cause tests to indicate failure incorrectly.