Subscribe by Email


Monday, January 23, 2012

What are different test cases for testing web application cookies?

To carry out any testing, you need to create effective test cases. Then only you will be able to fetch more appropriate outcomes from the testing. To develop effective test cases for web site cookie testing, you need to understand how the cookies are stored and managed.

Whenever you use a web site a cookie will get written on to your hard disk. Normally cookies are stored in the following format:

Site: abc.com RMID (name of the cookie)
Name: RMID
Content: 1d14c8ec45bf79e0… (Written in Encrypted format)
Domain: .abc.com
Path: / (the path after the name of the domain)
Send For: the type of the connection
Expires: Tuesday, December 31, 2015 10:25:25 PM date of expiry as set by the developer)

The cookies are used for the following applications:

1.Implementation of the shopping cart:
Cookies are used to implement online product or service ordering system. Cookies are a way to remember what the user wants to purchase. Suppose, if at the instant of time the customer adds some products to his carts and closes the browser window, then the cookie remembers what he/ she wants to buy and the customer can see ll those products.

2. Personalized web sites:
When we are browsing and visit certain pages. We are asked whether or not to display this page. The user instruction is stored in the cookie and those pages are displayed or not displayed as per the wish of the user.

3. Marketing:
Cookies are extensively used to advertise on the web sites. These advertisements are controlled by the cookie itself.

4. User tracking:
Cookies are used to track the number of visitors of a web site.

5. User sessions:
User sessions can be tracked using the cookie using the contained user ID and the password.

Apart from the benefits, the cookies have some drawbacks also. These are:
- Some times disabling the cookies can lead to disabling of the site itself.

- If too many cookies are being written on each and every page navigation, and if the cookies are enabled, this can lead to user frustration can result in the loss of traffic.

- Cookies are concerned with security also.

- Some cookies contain user’s personal information and if they are hacked, then the hacker gets access to the user’s personal information.

- Some sites store your sensitive information cookies. This is not advisable since it can lead to serious privacy concerns.

Test Cases for testing Web Application Cookies

- First test case should test whether the application is writing the cookies on the disk properly or not?

- The privacy policy of the cookie makes sure that your personal information is not written in to the cookie. It also makes sure that no sensitive data is leaked.

- Even if some sensitive data is stored in the cookies, it is made sure that the data is stored in the encrypted format.

- Overuse of cookies can annoy the users if the browser prompts for cookies frequently. This can cause loss of traffic of the web site.

- Disabling of cookies can cause some functionalities of the web site to become disabled or the site may not function properly. But always ensure that there is no page crash during the testing. Delete all the previous cookies.

- Acceptation and rejection of some cookies: this is probably the best way to check the functionality of site. All you have to do is accept only some of cookies and reject the others. For executing this case, you can set your browser settings so as to prompt you whenever a cookie is being written so that you can accept or reject that cookie. Observe the behavior of site.

- Corruption of cookies by editing their content.

- Testing of cookie on multiple browsers.


No comments:

Facebook activity