Making Good Test Cases Great
As we already know from the latest article, test cases are used to determine the functionality’s compliance with the stated requirements. So let’s take this to the another level and get into details of cool test scenarios.
Well-Tried Structure
Our experience shows that test cases should be written by a certain pattern. It streamlines the process of using them on the project. A right test scenario should include the following items:
- Description – reflects the inspection purpose.
- Pre-condition (preliminary steps) – contains a list of steps to complete before the testing.
- Steps – the testing method described in particular phases.
- Expected result – the intended system behavior after passing through the Steps.
- Case status – depends on correspondence of actual testing results to the expected ones.
These items are the obligatory minimum. However, in some cases it is practical to expand this set. Scenarios might also include such items as inspection priority, the flag of including in auto-tests, id of found bugs related to testing and others.
Essential Test Case Requirements
- Mutual independence. Tests might be enlarged, changed and deleted, and if they’re connected to cases, it creates chaos. In addition, the interrelation can mislead project manager into believing that the product’s operation meets expectations.
- Clear definitions and a high probability of error detecting.
- A detailed, but not excessive information. If the authorization process is subject to testing, the case should contain a username and a password.
- Easy error diagnosis. The detected bug should be obvious.
- The study of corresponding areas, carrying out relevant actions.
Test Designer Functions
Writing test cases is a complex process that requires not only a thorough project comprehension, but also certain skills. Due to that, qualified test designers should:
- Establish effective communication with developers, managers and users to collect consistent data on the project and QA analysis conduct.
- Correctly separate important tasks from less significant.
- See the whole system and efficiently decompose it to test every single feature.
- Precisely summarize his thoughts and get the message across to his teammates and customers.
- Featly apply all the techniques of test design.
It is essential to choose the right test design technique, because test efficiency depends on it.
You can create huge number of test cases, which we will not even be able to perform, or they will just identify only trivial problems. Only properly chosen technique will minimize the number of tests that must be passed to identify serious errors.
What’s Next?
Now we send test cases to the review and then - either to the automation or in manual testing plan.
Keep in mind that the automated tests require a more complete description, including, for example, the dependent values for the calculation. To the manual testing this level of specification does not make sense, as well as for small-scale projects; especially for stable companies with a small staff turnover, where large amounts of thoroughly described test cases is the extra maintenance costs of testing.
What are the results?
1. Positive, when the expected result matches the actual.
2. Negative, when the expected result is inconsistentwith the actual, an error is detected.
There is a third option when some bug may block the testing process. Therefore, in fact, we can only get two option. Not in the same time, of course. Each particular test case is designed to solve a specific problem, check the certain "chain" element. Thus, the expected outcome for this element is always singular.
Some Useful Tips!
We would like to share with you a couple of good ones:
- Start testing as early as possible, even before the first build.
- Carry out the positive tests first, and only then proceed to the negative ones.
- Begin with simple checks. Use standard user data input into the system. If the test fails even with these values, the first problems are already in your hands.
- Decompose your software into separate modules, and write a checklist for each one.
- Update the tests as soon as you detect the error or change the functionality.
Good luck!