Friday, December 7, 2012

Test Case

Test Case: is a set of conditions or laws which a tester uses to determine the correct functioning of a module or application/software.

You may need more than one test case to validate the functional working of a module.

Writing test cases is essential to trace the test coverage. It helps in minimizing redundant test cases and increases speed of test cycle. It also assists developers in understanding the issues/defects/errors/glitches associated with the software and increases maintenance speed.

Test Cases and Test scenarios.



Sample Test Case for Login form and Logout button:

  1. Enter valid email-id and password and then click on submit button.
    • Should take you to successful Login page.
  2. Enter invalid email-id and invalid password and then click on submit button.
    • Should not log you in.
    • It should show validation messages. Ex: "Invalid username or password".
    • Fields having errors should not be highlighted as user should not know whether email-id is wrong or password is wrong. 
  3. Enter valid email-id and invalid password and then click on submit button.
    • Should not log you in.
    • It should show validation messages. Ex: "Invalid username or password".
    • Fields having errors should not be highlighted as user should not know whether email-id is wrong or password is wrong. 
  4. Enter invalid email-id and valid password and then click on submit button.
    • Should not log you in.
    • It should show validation messages. Ex: "Invalid username or password".
    • Fields having errors should not be highlighted as user should not know whether email-id is wrong or password is wrong. 
  5. Click on submit button leaving email and password fields null.
    • Should not log you in.
    • It should show validation messages. Ex: "Please enter your email address" and "Password can't be blank"
    • Now fields having errors should be highlighted [Usually red in color].
  6. Check if form fields and buttons are aligned properly.
    • Verify if buttons should be round cornered.
    • Verify if text fields border should be round cornered.
    • Check if asterix(*) and help texts are aligned properly.
    • Check if help text and text fields are aligned properly.
    • Check if loading gif image has to be loaded after clicking on submit button.
  7. Verify whether validations are handled properly.
    • Validation messages should be meaningful and relevant to error event.
  8. After logging in successfully, copy the url and place it in a different browser.
    • It should get routed to login page instead of keeping you logged in, as you have placed the url in different browser and session has not yet being created for that browser.
  9. Close browser tab after logging in successfully and open page again by placing the copied url.
    • Now closing the browser tab should not end the session unless you click on Logout button. So instead of showing login form again it should take you to page 2 - which is successful login page.
  10. After Logout click on browser back button.
    • Clicking on browser back button after Logging out should not take you to page 2. Instead it should get routed to login page since session has been destroyed after logout.




No comments:

Post a Comment

I would like to thank you for your comments..! Please keep commenting. To get posts and updates via mail, I would suggest you to subscribe the Blog. Thanks Again..!

Google Search