What is Test Scenario? Template with Examples
What is a Test Scenario?A TEST SCENARIO is defined as any functionality that can be tested. It is also called Test Condition or Test Possibility. As a tester, you should put yourself in the end user’s shoes and figure out the real-world scenarios and use cases of the Application Under Test.
Scenario Testing in software testing is a method in which actual scenarios are used for testing the software application instead of test cases. The purpose of scenario testing is to test end to end scenarios for a specific complex problem of the software. Scenarios help in an easier way to test and evaluate end to end complicated problems.
Let’s study this with the help of the video below -
Why create Test Scenarios?
Test Scenarios are created for the following reasons,
- Creating Test Scenarios ensures complete Test Coverage
- Test Scenarios can be approved by various stakeholders like Business Analyst, Developers, Customers to ensure the Application Under Test is thoroughly tested. It ensures that the software is working for the most common use cases.
- They serve as a quick tool to determine the testing work effort and accordingly create a proposal for the client or organize the workforce.
- They help determine the most important end-to-end transactions or the real use of the software applications.
- For studying the end-to-end functioning of the program, Test Scenario is critical.
When not create Test Scenario?
Test Scenarios may not be created when
- The Application Under Test is complicated, unstable and there is a time crunch in the project.
- Projects that follow Agile Methodology like Scrum, Kanban may not create Test Scenarios.
- Test Scenario may not be created for a new bug fix or Regression Testing. In such cases, Test Scenarios must be already heavily documented in the previous test cycles. This is especially true for Maintenance projects.
How to Write Test Scenarios
As a tester, you can follow these five steps to create Test Scenarios-
- Step 1: Read the Requirement Documents like BRS, SRS, FRS, of the System Under Test (SUT). You could also refer uses cases, books, manuals, etc. of the application to be tested.
- Step 2: For each requirement, figure out possible users actions and objectives. Determine the technical aspects of the requirement. Ascertain possible scenarios of system abuse and evaluate users with hacker's mindset.
- Step 3: After reading the Requirements Document and doing your due Analysis, list out different test scenarios that verify each feature of the software.
- Step 4: Once you have listed all possible Test Scenarios, a Traceability Matrix is created to verify that each & every requirement has a corresponding Test Scenario
- Step 5: The scenarios created are reviewed by your supervisor. Later, they are also reviewed by other Stakeholders in the project.
Tips to Create Test Scenarios
- Each Test Scenario should be tied to a minimum of one Requirement or User Story as per the Project Methodology.
- Before creating a Test Scenario that verifies multiple Requirements at once, ensure you have a Test Scenario that checks that requirement in isolation.
- Avoid creating overly complicated Test Scenarios spanning multiple Requirements.
- The number of scenarios may be large, and it is expensive to run them all. Based on customer priorities only run selected Test Scenarios
Example 1: Test Scenario for eCommerce Application
For an eCommerce Application, a few test scenarios would be
Test Scenario 1: Check the Login Functionality
In order to help you understand the difference Test Scenario and Test Cases, specific test cases for this Test Scenario would be
- Check system behavior when valid email id and password is entered.
- Check system behavior when invalid email id and valid password is entered.
- Check system behavior when valid email id and invalid password is entered.
- Check system behavior when invalid email id and invalid password is entered.
- Check system behavior when email id and password are left blank and Sign in entered.
- Check Forgot your password is working as expected
- Check system behavior when valid/invalid phone number and password is entered.
- Check system behavior when "Keep me signed" is checked
As evident, Test Cases are more specific.
Test Scenario 2: Check the Search Functionality
Test Scenario 3: Check the Product Description Page
Test Scenario 4: Check the Payments Functionality
Test Scenario 5: Check the Order History
Apart from these 5 scenarios here is the list of all other scenarios
- Check Home Page behavior for returning customers
- Check Category/Product Pages
- Check Customer Service/Contact Pages
- Check Daily Deals pages
Example 2: Test Scenarios for a Banking Site
Test Scenario 1: Check the Login and Authentication Functionality
Test Scenario 2: Check Money Transfer can be done
Test Scenario 3: Check Account Statement can be viewed
Test Scenario 4: Check Fixed Deposit/Recurring Deposit can be created
And so on…