How to write test cases for registration and login page

Page 1

How to write test cases for registration and login page Writing test cases (which is an important task for a tester in application testing) requires experience and a keen eye for detail to build scenarios. This means that an application tester needs to focus on creating a set of variables or conditions which will help him to determine whether the software meets requirements and functions lawlessly. To reduce that hassle, we have compiled a list of use cases that you need to test a signup or login page. We hope they will help you to create more error-free Register/Login pages.

Before We Start You should gather all the customer requirements you can. The list of requirements which can be useful are: 1. 2. 3. 4. 5. 6.

FirstName Confirm Password LastName Address UserName PhoneNumber


7. Email ID 8. Gender 9. Password Required fields are: 1. 2. 3. 4.

Email ID UserName Password Confirm Password

Validation for fields: 1. Email 2. Password: It should have alphanumeric, Length should be 8 to 32. 3. PhoneNumber: Phone Number should have only Numbers, Country code is required After successful Verification email should send to the user On Required fields * should show. Now, let’s begin with our test cases. Although most testers use Bugzilla or other test management tools to maintain test cases, you can also use Excel or spreadsheets.

Test Cases for Registration Page Signup and login page by assuming some client requirements, such as: • Username and password are mandatory fields • There is cancel and


reset button at the bottom of the form • Radio buttons and checkboxes are placed correctly • The limit of the Password should be 8-13 characters (alphanumeric).

Sr Test Featur N Case e o. s

Descriptio n

Steps To Test Data / Execute Input

Expect ed Results

1

TC-0 01

User Interfa ce

Check all the text boxes, radio buttons, buttons, etc

1. Click on N/a Radio buttons, buttons and dropdow ns

UI should be perfect

2

TC-0 02

Requir ed fields

Check the required fields by not filling any data

1. Do not N/a enter any value in the field. 2. Click on the Register button.

It should show a mandat ory symbol (*) on mandat ory fields.


3

TC-0 03

Requir ed fields

Check user should Register by filling all the required fields

1. Enter valid values in the required fields. 2. Click the Register button.

N/a

1. Users should be register ed success fully. 2. A success ful registra tion messag e should show. 3. Mail should send to the user


4

TC-0 04

Option al Fields

Check all the optional fields when do not fill data

1. Do not N/a enter any detail in optional fields 2. Enter valid data in required fields 3. Click on the Signup button

1. It should not ask to fill the optional fields 2. User should be register ed success fully 3. A success ful registra tion messag e should show 4. Mail should send to the user


5

TC-0 05

Option al Fields

Check all the optional fields when filling data

1. Enter N/a valid data in optional fields 2. Enter valid data in required fields 3. Click on the Register button

1. User should be register ed success fully 2. A success ful registra tion messag e should show 3. Mail should send to the user


6

TC-0 06

Email • Check the validati Email text on field that has an Email address without @ symbol. • Check the Email text field that has a random string instead of a real email. • Check the Email text field that has @ symbol written in words. • Check the Email text field that has a missing dot in the

1. Enter Invalid Emails 2. Click on the Register Button.

1.testAtgmail. com 2.test@gmailc om 3.test@gmail 4.@gmail

It should show the validati on messag e for valid email


email address. 7

TC-0 07

Email Check all validati the valid on emails

1. Enter valid Emails 2. Click on the Register Button.

1.test.22@gm ail.com 2.test@gmail. com

8

TC-0 08

Phone Numbe r validati on

Check the phone number when passing alphanume ric data

1. Enter 1. alphanum dada5$7567#7 eric data in phone field 2. Click on Register button

9

TC-0 09

Phone Numbe r validati on

Check the phone number when not pass country code

1. Enter valid phone number without country code

It should not show any validati on messag e It should show the validati on messag e 8 for Phone Number

1. 9012078654 It should show the validati on messag e for


10 TC-01 Phone 0 Numbe r validati on

Check the phone number when passing country code

11 TC-01 Passwo Check the 1 rd password Validati limit when on enter value less than min

2.Click on Register button

country code is require d

1. Enter 1. +9190112244 valid phone number with country code 2.Click on Register button

It should not show any validati on messag e

1. Enter 1. Password value which is alphanum eric but less than 8. 2.Click on Register button

It should show validati on messag e


12 TC-01 Passwo Check the 2 rd password Validati limit when on enter value greater than max

1. Enter Any Random alphanum string with eric value numbers but more than 32. 2.Click on Register button

It should show validati on messag e

13 TC-01 Passwo Check the 3 rd password Validati when on passing only numbers

1. Enter a 1. 12345678 value in numbers which is in between 8-32 2.Click on Register button

It should show validati on messag e

14 TC-01 Passwo Check the 4 rd password Validati when on passing valid data

1. Enter 1. Pass123456 value in alphanum eric which is in between 8-32 2.Click on Register button

It should not show any validati on messag e


15 TC-01 Requir 5 ed Fields

Verify if blank spaces are passed in required fields.

1. Go to N/a the Site. 2. Passed blank spaces in required fields. 3. Click on the Register button

Those Blank spaces should trim and Validati on error messag e for require d fields should visible.

16 TC-01 Requir 6 ed Fields

Verify user 1. Go to test22@gmail. User can verify the Email. com should its Email ID 2. Click get a on the verifica verificati tion link on link. and able to verify his/her Email ID.


17 TC-01 Phone 7 Numbe r Validati on

Verify if the length of the phone number is incorrect i.e. less than 10.

1. Enter 91901122 phone number less than 10 digits. 2.Enter all required fields. 3.Click on Register Button

It should show the validati on error messag e for phone number length.

18 TC-01 Phone 8 Numbe r Validati on

Verify if the length of the phone number is incorrect i.e. more than 10

1. Enter 9190112244556 It phone 6 should number show less than the 10 digits. validati 2.Enter on error all messag required e for fields. phone 3.Click on number Register length. Button


19 TC-01 Passwo Verify if 9 rd the Validati password on required rules are not satisfied in the password

1. Enter passw the password which not satisfies the required rule. 2.Click on Register button

It should display error with require d rules for passwo rd value (like it should contain a special charact er, a small case, a number )

Test Cases for Login Page Sr Test Feature No. Cases

Description

Steps To Execute

Expected Results


1

TC-01

User Check all the text Check Page • UI Interface boxes and buttons should be perfect • Text boxes and button should be aligned

2

TC-02 Required Check the required 1. Enter Fields fields by not filling invalid any data. username 2. Enter correct password 3. Click on Login Button

User should not log in and should show proper error message

3

TC-03 User Login

User should not log in and should show proper error message

Check When passing a correct username and invalid password

1. Enter valid username 2. Enter incorrect password 3. Click on Login Button


4

TC-04 User Check Keeping Interface Password

1. Enter valid username 2. Do not enter password 3. Click on Login Button

User should not log in and should show proper error message

5

TC-05 User Login

Check when pass correct email and password

1. Enter valid username 2. Enter valid password 3. Click on Login Button

User should log in

6

TC-06 User Login

Check if the password is entered in encrypted

1. Enter valid username 2. Enter password 3. Click on Login Button

Password is entered in encrypte d form


7

TC-07 Signup Option for new users

Check whether the Click Signup signup link for the link new user is working

Clicking signup link takes the user to signup page successf ully

8

TC-08 Forgot Verify user should Password get an error message when he/she enters not registered email id.

1. Click on the Forgot password link. 2. Enter unregistere d email id and click on the send button.

User should get an error message.

9

TC-09 Reset Verify user should Password get an error message when he/she enters the previous password.

1. Go to the reset password link. 2. Enter the previous password. 3. Click on the Reset Password button.

User should get an error message.


10

TC-10

Reset Verify user able to Password reset his/her password

1. Go to the reset password link. 2. Enter a new password and a confirm password. 3. Click on the Reset Password button.

Users should get the success message and the password should get reset.

11

TC-11

Reset Verify user should Password get an error message when password and confirm password not matches

1. Go to the reset password link. 2. Enter a different new password and a confirm password. 3. Click on the Reset Password button.

Users should get an error message.


12

TC-12

Reset Verify user should 1. Go to the Password able to login with a reset new password. password link. 2. Enter a new password and a confirm password. 3. Click on the Reset Password button. 4. Log in by using the new password.

User should able to login


13

TC-13

Reset Verify if the user Password enters a new password that does not cover the basic requirements of password then the user should be displayed error message

1. Go to the reset password link. 2. Enter a new password that does not cover the basic requiremen ts. 3. Click on the Reset Password.

Users should get an error message.

14

TC-14

Required Verify if blank 1. Go to the Fields spaces are passed Site. in required fields. 2. Passed blank spaces in required fields. 3. Click on the Login button

Those Blank spaces should trim and Validatio n error message for required fields should visible.


15

TC-15

Welcome Verify new users Email should get the welcome email once after the login.

1. Go to the Email. 2. Enter Login Email.

Users should get a welcome email on his/her email id.

16

TC-16

User Login

Verify when passing incorrect Email and correct password

1. Enter incorrect Email. 2. Enter the correct password. 3. Click on the Login Button.

User should not be able to log in and the error message should be displayed .

17

TC-17

User Login

Verify when passing both incorrect Email and password

1. Enter incorrect Email. 2. Enter the correct password. 3. Click on the Login Button

User should not be able to log in and the error message should be displayed .


18

TC-18

User Forgot Password .

Verify Forgot Password sends a forgot password link.

1. Click on the Forgot Password link. 2. Enter Email and click on the send button. 3. Now go to mail7.io and enter the email id.

User should get the forgot password link on his/her email id.

Conclusion You need to think like an end-user for writing the best test cases and getting different scenarios of what will happen in real circumstances. If you install this creativity and perceive the product with the eyes of an end-user, you will certainly be closer to creating an error-free application. BE A PERFECTIONIST. HAPPY TESTING!


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.