Testers should be using the industries best tools to find bugs before software ships. This article aims to make software testers aware of SQL Table Audit by Renhold Software.
One of the most important points in SQATesters qualities of a good tester article is being skeptical, but how does this apply to software testing? It means not trusting just what the application tells you but finding other evidence to validate that your test was a success.
The idea of using an auditing tool for testing is simple, The auditing tool will record every data change on the database or a given set of tables, then you can use the data in the audit log to validate that your tests are a success.
So what is SQL Table Audit? It is a tool that installs table triggers into your database to record all data changes for audited tables. It has extensive audit log viewing and filtering capabilities for finding out exactly how the data is changing in your database.
A simple example; Imagine that you are testings a set of CRUD operations for stored addresses. You update an existing address then check that the address has been updated by using the address view page/form within the application. The change appears to have worked, great… or is it. Could it be what actually has happened is the application has updated its cached version of the data but not actually persisted those changes to the database. An easy way of finding out would be to check the audit log for the database.
Finding the data changes that your tests have caused is easy. SQL Table Audit has powerful audit filtering capabilities that allow you to find changes by table, date and time, type (insert, update, delete), the data that changed (old value and new value), columns, user and application.
A great work flow for testers using SQL Table Audit is to; Add auditing to the whole database or selected tables, Do the test, Then check the audit log to ensure that the correct data got updated, inserted or deleted.
Testing can often mean repeating the same test using different parameters. By using the powerful rewind functionality included you can rewind data changes that have happened in the course of a test, then try the test again. This can save hours of work redeploying or resetting a test environment.
After testing, SQL Table Audit can clean up after itself by removing all auditing objects from the database.
By using industry standard tools like SQL Table Audit by you can help minimize the risk of bugs getting shipped and improve the quality of software that you test.