How to Do a Smoke Test
Table of Contents
What Is Smoke Testing?
Smoke testing in software is a quick test done after a build has completed successfully, but before QA fully tests it.
Microsoft claims that after code reviews, smoke testing is the most cost-effective method for identifying and fixing defects in software.
The sooner you find a defect, the cheaper it is to fix it. That's why it's important to automatically perform a smoke test each time a build finishes.
Smoke testing lets developers know right away if something that they checked in recently caused a problem.
Back to topHow to Do a Smoke Test
The process to implement an automated smoke test will vary depending on your application and the configuration of your build tool. But the basic steps of smoke testing should remain the same.
1. Prepare for Testing.
After you've completed the build successfully — and before you test your application — you may need to perform setup steps. This might include copying files to the appropriate places, setting up database tables, installing licenses, or starting a server.
2. Get Your Test Files.
Your next step is to gather the files required for your smoke test. If you're using smoke testing software from Perforce, you would use the command line to fetch several smoke test files to the local drive.
3. Write a Script.
Using a single script for smoke testing will give you more flexibility (while keeping the build script static). Your smoke test should run run from your build tool. Once it has run, its report should be saved with the rest of the build files. If something fails, it needs to be reported to the developers (along with an output of the script).
If you're using smoke testing software from Perforce, your script would be similar to: "C:Program FilesSeapineQA Wizard ProQAWRunScript.exe" "SmokeTestSmokeTest.qawwspace" "SmokeTestSmokeTest.qawscript" /Reportfile "BuildCurrentReport.qawreport"
4. Clean Up.
After the smoke test, you need to clean up. This might include stopping a server, deleting files, or emptying database tables. This could also be done before the initial setup step to ensure that the environment is clean before any tests are started.
Need more testing help? Learn about exploratory testing >>
Whether you struggle with smoke testing or different types of software testing, you're not alone.
👉🏽 Learn four reasons why software testers struggle — and what you can do about them.
Note: This post was originally published on June 10, 2009 and has been updated for accuracy and comprehensiveness.
Back to top