Elastic Path's QA team is using ApTest as its test case repository. The tool is online, so we can access it on or off site. We have divided testing of our application into modules based on the functional areas; ie, order modifications, catalog management, import/export, payment gateways, reporting, promotions, etc.
Each each release has its own test suite. We use the release as the suite name, ie. Release 6.1. The Release 6.1 suite includes all the test cases from previous releases plus test cases for new functionality added in 6.1. For the next release, 6.1.1, we will copy the Release 6.1 suite to a new suite called Release 6.1.1 and add new functionality test cases to it as well. This method allows us to go back to each release and know what has been added, what is new and what we have covered so far. When there are changes to existing functionality, we deal with the changes by making sure we keep test cases up to date.
We have both manual and automated test cases in ApTest. Manual test cases have a full description, pre- and post-conditions, and expected result(s). For automated test cases, we have only placeholders in ApTest. We use Fit for business logic. (Fit will be discussed in more detail in another post). The Fit tests run automatically at build time and we parse the results back into ApTest. This helps us for reporting purposes.
Test cases are run as part of a session. The session can be one big session containing all the test cases, or small sessions based on the functional areas with test cases specific to that functional area.
Writing test cases
After logging in to ApTest, click the suites button (the second button next to help, which looks like a color palette) to list all the suites that you have access to. Then select the suite you want by clicking the link. Select 'Specify Test Cases for this Test Suite'. On the left hand side, you can see the module names. Select one. In the frame on the right side, you can see either the test cases in a grid table or some other folders (these are the subfolders under the selected module). In the right side frame, at the top next to the module name/test case name, there are some buttons:
- 'Make a new folder': This creates subfolder under the specific module you are working in.
- 'Make a new Test Case': This will open the template for test cases and you can fill up the necessary information and create the test cases.
- 'Rename/Move Folder': This will allow renaming of the folder or the subfolder currently in; also it allows moving the folder to some other place within the same suite.
- 'Delete Folder': This will allow deletion of the folder or subfolder currently working in.
- 'Copy Folder': This will copy the current folder and test cases within the same suite.
- 'Manage Folder': This would allow adding description to the folder or locking the folder.
- 'Find and Replace': This gives the search capability within the current folder and its subfolders.
- 'Upload File': This will allow upload of a file such as .csv or .txt files
- 'Import Tests': This will allow mass import of test cases.
- 'Arrange test cases and folders': This would allow the folder and test case ordering.
Running test cases
On the page directed to by selecting the release, select 'Execute Test Cases in this Test Suite'. In order for test cases to run we need to have a set of test cases in a session.
If you already have a session, select your session from the table, check the check mark next to the session, and click the yellow/green foot shape icon.
If you don't have a session, you need to create the sets and sessions.
- Click the 'Administer Sets and Sessions' button at the top of the page. On the right side frame on top next to the release name there are few buttons.
- Click 'Add a New Folder' to create a folder.
- Click 'Add a New Test Set'. Give a meaningful name to the test set and select test cases, or any of the functional area, version, who created it or priority. Create the test set.
- In the test set table, find your test set just created.
- Next to the test set, there is a tiny file with a green + next to it labelled 'Create Test Session'. Click it. Name your session and select your parameters. The test environment set up is pretty much what your test server settings are. Then create test session.
- Now you can find this session in the session table, check the check mark next to it, and click the yellow/green foot shape icon.
Now you can go through test cases one by one and flag them as failed, passed or ignored.