Lecture 16
Lecture 16
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.
https://www.youtube.com/watch?time_continue=6&v=wMN0pCyjQ9E&feature=emb_logo
As a tester, you can follow these five steps to create Test Scenarios-
● Step 1: Read the Requirement Documents, 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.
● 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
A use case is a description of a particular use of the system by an actor or user. It is used widely
in developing tests at system or acceptance level.
In a use-case, an actor is represented by "A" and system by "S". We create Use for a login
functionality of a Web Application as shown below
Example 1: Test Scenario for eCommerce Application
1. Check system behavior when valid email id and password is entered.
2. Check system behavior when invalid email id and valid password is entered.
3. Check system behavior when valid email id and invalid password is entered.
4. Check system behavior when invalid email id and invalid password is entered.
5. Check system behavior when email id and password are left blank and Sign in entered.
6. Check Forgot your password is working as expected
7. Check system behavior when valid/invalid phone number and password is entered.
8. Check system behavior when "Keep me signed" is checked
1. Verify that user can set profile pic uploaded from his or her computer.
2. Verify that user can set profile pic uploaded from mobile.
3. Verify that uer can set profile pic from photos present on his facbook account’s
photo section.
4. Verify that user can set profile from webcam or mobile camera.
5. Verify that user can set cover pic uploaded from his or her computer.
6. Verify that user can set cover pic uploaded from mobile.
7. Verify that user can set cover pic from photos present on his facbook account’s
photo section.
8. Verify that user can set cover from webcam or mobile camera.
9. Verify that uploading image of unsupported type should lead to error message.
10.Verify that uploading image of size exceeding maximum allowed size should lead
to error message.
11.Verify that uploading image of size less than the allowed minimum size should
lead to error message.
12.Verify that uploading image of larger dimension than permitted should lead to
error message.
13.Verify that uploading image of smaller dimension than permitted should lead to
error message.
14.Verify that change in profile pic should get reflected in each post/comment of the
user’s timeline.
15.Verify that user can add/edit their account information displayed to other users.
16.Verify that users can post text in their timeline and the same gets displyed to their
friends.
17.Verify that users can post images in their timeline and the same gets displyed to
their friends.
18.Verify that users can post links with or without preview in their timeline and the
same gets displayed to their friends.
19.Verify that user can tag friends in their posts.
20.Verify that users can see the all the post in their timeline.
21.Verify that users can see comments, likes and reactions in the posts present in their
timeline.
22.Verify that users can post comments, like and react to the posts present in their
timeline.
Friends and their Timelines Scenario
1. Verify that the user can search for friends in facebook’s ‘Find friends’ search
functionality.
2. Verify that users can send a friend requests to any user by visiting their page.
3. Verify that the user can navigate through their Friend’s friend and send a friend
requests to them.
4. Verify that the user can approve or decline received friend request.
5. Verify that the user can unfriend any existing friend.
6. Verify that users can see the timeline of their friends.
7. Verify that users can post text in their friend’s timeline.
8. Verify that users can post images in their timeline and the same gets displayed to
their friends.
9. Verify that users can post links with or without preview in their friend’s timeline.
10.Verify that users can tag friends in their posts on a friend’s timeline.
11.Verify that users can see all the posts in their friend’s timeline.
12.Verify that users can see comments, likes, and reactions in the posts present in
their friend’s timeline.
13.Verify that users can post comments, like and react to the posts present in their
friend’s timeline.
1. Verify that users receive different notifications on facebook ‘Notifications’ icon.
2. Verify that users receive different notifications on email or cell phone based on the
settings chosen when not logged in to Facebook.
3. Verify that users receive a notification when their friend request gets approved.
4. Verify that users receive a notification when they get a friend request.
5. Verify that users receive a notification when they get tagged by someone on posts
or comments.
6. Verify that users receive a notification when they get comments, like or reactions
on their posts.
7. Verify that users receive notification when someone posts on their timeline.
Examples: https://artoftesting.com/test-scenario-examples
A TEST CASE is a set of actions executed to verify a particular feature or functionality of your
software application. A Test Case contains test steps, test data, precondition, postcondition
developed for specific test scenario to verify any requirement. The test case includes specific
variables or conditions, using which a testing engineer can compare expected and actual results
to determine whether a software product is functioning as per the requirements of the customer.
https://www.youtube.com/watch?v=BBmA5Qp6Ghk&feature=emb_title
For a Test Scenario: Check Login Functionality there many possible test cases are:
Let’s create a Test Case for the scenario: Check Login Functionality
Step 2) In order to execute the test case, you would need Test Data. Adding it below
Step 3) In order to execute a test case, a tester needs to perform a specific set of actions on the
AUT. This is documented as below:
Step 4) The goal of test cases is to check behavior the AUT for an expected result. This needs to
be documented as below
During test execution time, the tester will check expected results against actual results and assign
a pass or fail status
Step 5) That apart your test case -may have a field like, Pre - Condition which specifies things
that must in place before the test can run. For our test case, a pre-condition would be to have a
browser installed to have access to the site under test. A test case may also include Post -
Conditions which specifies anything that applies after the test case completes. For our test case, a
postcondition would be time & date of login is stored in the database
While drafting a test case to include the following information
Create test cases that are as simple as possible. They must be clear and concise as the author of
the test case may not execute them.
Use assertive language like go to the home page, enter data, click on this and so on. This makes
the understanding the test steps easy and tests execution faster.
The ultimate goal of any software project is to create test cases that meet customer requirements
and is easy to use and operate. A tester must create test cases keeping in mind the end user
perspective
Do not repeat test cases. If a test case is needed for executing some other test case, call the test
case by its test case id in the pre-condition column
4. Do not Assume
Do not assume functionality and features of your software application while preparing test case.
Stick to the Specification Documents.
Make sure you write test cases to check all software requirements mentioned in the specification
document. Use Traceability Matrix to ensure no functions/conditions is left untested.
Name the test case id such that they are identified easily while tracking defects or identifying a
software requirement at a later stage.
It's not possible to check every possible condition in your software application. Software Testing
techniques help you select a few test cases with the maximum possibility of finding a defect.
● Boundary Value Analysis (BVA): As the name suggests it's the technique that defines
the testing of boundaries for a specified range of values.
● Equivalence Partition (EP): This technique partitions the range into equal parts/groups
that tend to have the same behavior.
● State Transition Technique: This method is used when software behavior changes from
one state to another following particular action.
● Error Guessing Technique: This is guessing/anticipating the error that may arise while
doing manual testing. This is not a formal method and takes advantages of a tester's
experience with the application
8. Self-cleaning
The test case you create must return the Test Environment to the pre-test state and should not
render the test environment unusable. This is especially true for configuration testing.
The test case should generate the same results every time no matter who tests it
After creating test cases, get them reviewed by your colleagues. Your peers can uncover defects
in your test case design, which you may easily miss.
https://drive.google.com/uc?export=download&id=0ByI5-ZLwpo25eXFlcU5ZMTJsT28
https://octopuscourses.testrail.io/
It is used to track the requirements and to check the current project requirements are met.
Requirement Traceability Matrix (RTM) is a document that maps and traces user requirement
with test cases. It captures all requirements proposed by the client and requirement traceability in
a single document, delivered at the conclusion of the Software devlopement life cycle. The main
purpose of Requirement Traceability Matrix is to validate that all requirements are checked via
test cases such that no functionality is unchecked during Software testing.
Why RTM is Important?
The main agenda of every tester should be to understand the client’s requirement and make sure
that the output product should be defect-free. To achieve this goal, every QA should understand
the requirement thoroughly and create positive and negative test cases.
This would mean that the software requirements provided by the client have to be further split
into different scenarios and further to test cases. Each of this case has to be executed
individually.
A question arises here on how to make sure that the requirement is tested considering all possible
scenarios/cases? How to ensure that any requirement is not left out of the testing cycle?
A simple way is to trace the requirement with its corresponding test scenarios and test cases.
This merely is termed as ‘Requirement Traceability Matrix.'
The traceability matrix is typically a worksheet that contains the requirements with its all
possible test scenarios and cases and their current state, i.e. if they have been passed or failed.
This would help the testing team to understand the level of testing activities done for the specific
product.
● Requirement ID
● Requirement Type and Description
● Test Cases with Status
https://docs.google.com/document/d/1FsLnZ4thNQF0MhFIFw2Q1KzOTAX89MB8BCvnpsPu5
Lc/edit
Both sets of requirements contribute to a common goal, although functional requirements are
much more specific and detailed. While business requirements deal with mainly business goals
and stakeholder expectations, functional requirements outline exactly how a project will support
business requirements.
https://www.youtube.com/watch?time_continue=2&v=cm-cSW66Isc&feature=emb_logo