Tuesday, 21 May 2013


Web Testing


Web Applications Testing


I) Overview:


 

Now a days Web Applications are getting more popular in the IT Industry, having so many advantages like supporting more clients, no client side installation and accessing from any ware etc…

 


Types of Web Application


 


We can categorize web applications in two ways


 


a)    Business Classification


 


1)     Web Sites (They provide information about Organizations or Industries or persons)


2)    Web Portals (They are Business gateways, ex: Online Shopping sites, Job portals etc.)


3)     Web Applications (They are Service providers (both Free and Paid), apart from information) Ex: Net Banking Applications, Insurance Applications etc…)


 


b)    Technical Classification


1)     Intranet Applications (They are private applications, uses local area network (LAN))


2)     Internet Applications (They are Public applications, uses Wide area network (WAN)


3)     Extranet Applications (They also Private applications over Internet (WAN))


 


Browser:


 

It is a Software Application, which retrieves, and Presents information in text, image and voice like different file formats.

 

The browser is the viewer of a Web Site and there are so many different browsers and browser options that a well-done Web Site is probably designed tolook good on as many browsers as possible.

 

Popular Browsers:

1)     Internet Explorer

2)     Mozilla Firefox

3)     Google Chrome

4)     Safari

5)     Opera

Etc…

 



         

Ø       HTML (Hyper Text Markup Language) – for displaying web pages

Ø       XML (Extensible Markup Language) –for Transporting the Data

Ø       Java Script – for Client Side Validations

Ø       VB Script – for Server side Validations

Ø       IIS, Apache, Tomcat, Pramathi – as Web servers

Ø       JBoss, WebLogic, WebSpeare, COM+ - as Application Servers

Ø       Java, C#.NET, VB.NET, VC++.NET for Components development

Ø       SQL Server, Oracle, MySQL  as Database Servers

Ø       HTTP, SOAP – as Protocols

 

 


 

Functionality Testing:


 

Test for - all the links in web pages, database connection, forms used in the web pages for submitting or getting information from user, Cookie testing.

 


Check all the links:


 


·                                             Test the outgoing links from all the pages from specific domain under test.

·                                             Test all internal links.

·                                             Test links jumping on the same pages.

·                                             Test links used to send the email to admin or other users from web pages.

·                                             Test to check if there are any orphan pages.

·                                             Lastly in link checking, check for broken links in all above-mentioned links.

 


Test forms in all pages:


 


Forms are the integral part of any web site. Forms are used to get information from users and to keep interaction with them. So what should be checked on these forms?

·                                             First check all the validations on each field.

·                                             Check for the default values of fields.

·                                             Wrong inputs to the fields in the forms.

·                                             Options to create forms if any, form delete, view or modify the forms.

 


Cookies testing:


 


Cookies are small files stored on user machine. These are basically used to maintain the session mainly login sessions. Test the application by enabling or disabling the cookies in your browser options. Test if the cookies are encrypted before writing to user machine. If you are testing the session cookies (i.e. cookies expire after the sessions ends) check for login sessions and user stats after session end. Check effect on application security by deleting the cookies.

 


Validate your HTML/CSS:


 


If you are optimizing your site for Search engines then HTML/CSS validation is very important. Mainly validate the site for HTML syntax errors. Check if site is crawl able to different search engines.

 


Database testing:


 


Data consistency is very important in web application. Check for data integrity and errors while you edit, delete, modify the forms or do any DB related functionality. Check if all the database queries are executing correctly, data is retrieved correctly and also updated correctly. More on database testing could be load on DB, we will address this in web load or performance testing below.

 


Usability Testing:


 


Test for navigation:


 

Navigation means how the user surfs the web pages, different controls like buttons, boxes or how user using the links on the pages to surf different pages.
Usability testing includes:
Web site should be easy to use. Instructions should be provided clearly. Check if the provided instructions are correct means whether they satisfy purpose. Main menu should be provided on each page. It should be consistent.

 


Content checking:


 


Content should be logical and easy to understand. Check for spelling errors. Use of dark colors annoys users and should not be used in site theme. You can follow some standards that are used for web page and content building. These are common accepted standards like as I mentioned above about annoying colors, fonts, frames etc.
Content should be meaningful. All the anchor text links should be working properly. Images should be placed properly with proper sizes.
These are some basic standards that should be followed in web development. Your task is to validate all for UI testing

 


Other user information for user help:


 


Like search option, sitemap, help files etc. Sitemap should be present with all the links in web sites with proper tree view of navigation. Check for all links on the sitemap.
“Search in the site” option will help users to find content pages they are looking for easily and quickly. These are all optional items and if present should be validated.

 


Interface Testing:


 


The main interfaces are:
Web server and application server interface
Application server and Database server interface.

Check if all the interactions between these servers are executed properly. Errors are handled properly. If database or web server returns any error message for any query by application server then application server should catch and display these error messages appropriately to users. Check what happens if user interrupts any transaction in-between? Check what happens if connection to web server is reset in between?

 


Compatibility Testing:


 


Compatibility of your web site is very important testing aspect. See which compatibility test to be executed:

·                                             Browser compatibility

·                                             Operating system compatibility

·                                             Mobile browsing

·                                             Printing options

 


 


Browser compatibility:


 


In my web-testing career I have experienced this as most influencing part on web site testing.
Some applications are very dependent on browsers. Different browsers have different configurations and settings that your web page should be compatible with. Your web site coding should be cross browser platform compatible. If you are using java scripts or AJAX calls for UI functionality, performing security checks or validations then give more stress on browser compatibility testing of your web application.
Test web application on different browsers like Internet explorer, Firefox, Netscape navigator, AOL, Safari, Opera browsers with different versions.

 


OS compatibility:


 


Some functionality in your web application is may not be compatible with all operating systems. All new technologies used in web development like graphics designs, interface calls like different API’s may not be available in all Operating Systems.
Test your web application on different operating systems like Windows, Unix, MAC, Linux, Solaris with different OS flavors.

 


Mobile browsing:


 


This is new technology age. So in future Mobile browsing will rock. Test your web pages on mobile browsers. Compatibility issues may be there on mobile.

 


Printing options:


 


If you are giving page-printing options then make sure fonts, page alignment, page graphics getting printed properly. Pages should be fit to paper size or as per the size mentioned in printing option.

 


Performance testing:


 


Web application should sustain to heavy load. Web performance testing should include:

Web Load Testing
Web Stress Testing

Test application performance on different internet connection speed.
In web load testing test if many users are accessing or requesting the same page. Can system sustain in peak load times? Site should handle many simultaneous user requests, large input data from users, Simultaneous connection to DB, heavy load on specific pages etc.

 

Stress testing:

 

Generally stress means stretching the system beyond its specification limits. Web stress testing is performed to break the site by giving stress and checked how system reacts to stress and how system recovers from crashes. Stress is generally given on input fields, login and sign up areas.
In web performance testing web site functionality on different operating systems, different hardware platforms is checked for software, hardware memory leakage errors,

 


Security Testing:


 


Following are some tests for web security testing:

·                     Test by pasting internal URL directly into browser address bar without login. Internal pages should not open.

·                     If you are logged in using username and password and browsing internal pages then try changing URL options

directly. I.e. If you arechecking some publisher site statistics with publisher site ID= 123. Try directly changing the URL site ID parameter to different site ID which is not related to log in user. Access should deny for this user to view others stats.

·    Try some invalid inputs in input fields like login username, password and input text boxes. Check the system   

             reaction on all invalid inputs.

·           Web directories or files should not be accessible directly unless given download option.

·           Test the CAPTCHA for automates scripts logins.

·           Test if SSL is used for security measures. If used proper message should get displayed when user switch from  

            non-secure http:// pages to secure https:// pages and vice versa.

·                     All transactions, error messages, security breach attempts should get logged in log files somewhere on web server.

 

 

 

 

 

 

Web Testing is an essential topic now a days

 

Software Test Metrics


This Document Explains:
1) Base Metrics (Direct Measure),
2) Calculated Metrics (Indirect Measure),
3) Base Metrics & Test Phases,
4) Calculated Metrics & Phases,
5) Crucial Web Based Testing Metrics,
6) Test Case defect density,
7) Defect Slippage Ratio,
8) Requirement Volatility
9) Review Efficiency 
10) Efficiency and Effectiveness of Processes
11) Metrics for Software Testing

Metrics for Software Testing


Test Coverage = Number of units (KLOC/FP) tested / total size of the system
Number of tests per unit size = Number of test cases per KLOC/FP
Acceptance criteria tested = Acceptance criteria tested / total acceptance criteria
Defects per size = Defects detected / system size
Test cost (in %) = Cost of testing / total cost *100
Cost to locate defect = Cost of testing / the number of defects located
Achieving Budget = Actual cost of testing / Budgeted cost of testing
Defects detected in testing = Defects detected in testing / total system defects
Defects detected in production = Defects detected in production/system size
Quality of Testing = No of defects found during Testing/(No of defects found during testing + No of acceptance defects found after delivery) *100
Effectiveness of testing to business = Loss due to problems / total resources processed by the system.
System complaints = Number of third party complaints / number of transactions processed
Scale of Ten = Assessment of testing by giving rating in scale of 1 to 10
Source Code Analysis = Number of source code statements changed / total number of tests.
Effort Productivity = Test Planning Productivity = No of Test cases designed / Actual Effort for Design and Documentation
Test Execution Productivity = No of Test cycles executed / Actual
Effort for testing

B) The product quality measures

 

1. Customer satisfaction index


(Quality ultimately is measured in terms of customer satisfaction.) 
Surveyed before product delivery and after product delivery 
(and on-going on a periodic basis, using standard questionnaires) 
Number of system enhancement requests per year 
Number of maintenance fix requests per year 
User friendliness: call volume to customer service hotline 
User friendliness: training time per new user 
Number of product recalls or fix releases (software vendors) 
Number of production re-runs (in-house information systems groups) 

2. Delivered defect quantities 

Normalized per function point (or per LOC) 
At product delivery (first 3 months or first year of operation) 
Ongoing (per year of operation) 
By level of severity 
By category or cause, e.g.: requirements defect, design defect, code defect, 
documentation/on-line help defect, defect introduced by fixes, etc. 


3. Responsiveness (turnaround time) to users 

Turnaround time for defect fixes, by level of severity 
Time for minor vs. major enhancements; actual vs. planned elapsed time 

4. Product volatility 


Ratio of maintenance fixes (to repair the system & bring it into 
compliance with specifications), vs. enhancement requests 
(requests by users to enhance or change functionality) 

5. Defect ratios 


Defects found after product delivery per function point 
Defects found after product delivery per LOC 
Pre-delivery defects: annual post-delivery defects 
Defects per function point of the system modifications 

6. Defect removal efficiency 


Number of post-release defects (found by clients in field operation), 
categorized by level of severity 
Ratio of defects found internally prior to release (via inspections and testing), 
as a percentage of all defects 
All defects include defects found internally plus externally (by 
customers) in the first year after product delivery 

7. Complexity of delivered product 


McCabe's cyclomatic complexity counts across the system 
Halstead’s measure 
Card's design complexity measures 
Predicted defects and maintenance costs, based on complexity measures 

8. Test coverage 


Breadth of functional coverage 
Percentage of paths, branches or conditions that were actually tested 
Percentage by criticality level: perceived level of risk of paths
The ratio of the number of detected faults to the number of predicted faults. 

9. Cost of defects 

Business losses per defect that occurs during operation 
Business interruption costs; costs of work-arounds 
Lost sales and lost goodwill 
Litigation costs resulting from defects 
Annual maintenance cost (per function point) 
Annual operating cost (per function point) 
Measurable damage to your boss's career 

10. Costs of quality activities 


Costs of reviews, inspections and preventive measures 
Costs of test planning and preparation 
Costs of test execution, defect tracking, version and change control 
Costs of diagnostics, debugging and fixing 
Costs of tools and tool support 
Costs of test case library maintenance 
Costs of testing & QA education associated with the product 
Costs of monitoring and oversight by the QA organization 
(if separate from the development and test organizations) 

11. Re-work 


Re-work effort (hours, as a percentage of the original coding hours) 
Re-worked LOC (source lines of code, as a percentage of the total delivered LOC) 
Re-worked software components (as a percentage of the total delivered components) 

 

12. Reliability 


Availability (percentage of time a system is available, versus the time 
the system is needed to be available) 
Mean time between failure (MTBF) 
Mean time to repair (MTTR) 
Reliability ratio (MTBF / MTTR) 
Number of product recalls or fix releases 
Number of production re-runs as a ratio of production runs

 

TEST CASES MANUAL TESTING

 

Coffee machine

 

1.Plug the power cable and press the on button. The indicator bulb should glow indicating the machine is on.

2. Whether there are three different buttons Red, Blue and Green.

3. Whether Red indicated Coffee.

4. Whether Blue indicated Tea.

5. Whether Green indicated Milk.

6. Whether each button produces the correct out put (Coffee, Tea or Milk).

7. Whether the the desired out put is hot or not (Coffee, Tea or Milk).

8. Whether the quantity is exceeding the specified the limit of a cup.

9. Whether the power is off (including the power indicator) when pressed the off button.

The scenario is " there are two notepad applications which were already open. In notepad1 some typed text is there. notepad2 is empty. Using cut and paste option u have to paste the entire text from notepad1 into notepad2."

Test Cases are considered for both the Notepads (Notepad1 and Notepad2) being open.

1. Press Ctrl+A from keyboard, checkout whether its selecting all the data. Similarly from notepad1 screen,select Edit and select Select All Option and check out whether all the data is selected.

2. Press Ctrl+C from keyboard, checkout whether you're able to copy the data from Notepad1 to Notepad2.Similarly from notepad1 screen,select Edit and select Copy Option,check out whether all the data is copied from notepad1.

3.Press Ctrl+V from keyboard, checkout whether you're able to Paste the data from Notepad1 to Notepad2.Similarly from notepad1 screen,select Edit and select Paste Option,check out whether all the data is pasted to notepad2.

4.Press Alt+F4 from Keyboard, check out whether its closes both the screens.Similarly check out the exit option in File.

5. After you press Ctrl+X from keyboard, check out for Ctrl+Z option from Keyboard, similarly check out for Undo option in Edit Menu.

For Web Applications what type of tests are you going to do?


Short release cycles;
- Constantly Changing Technology;
- Possible huge number of users during initial website launch;
- Inability to control the user's running environment;
- 24-hour availability of the web site.


The quality of a website must be evident from the Onset. Any difficulty whether in response time, accuracy of information, or ease of use-will compel the user to click to a competitor's site. Such problems translate into lost of users, lost sales, and poor company image.


To overcome these types of problems, use the following techniques:
1. Functionality Testing
Functionality testing involves making Sure the features that most affect user interactions work properly. These include:
· forms
· searches
· pop-up windows
· shopping carts
· online payments

2. Usability Testing
Many users have low tolerance for anything that is difficult to use or that does not work. A user's first impression of the site is important, and many websites have become cluttered with an increasing number of features. For general-use websites frustrated users can easily click over a competitor's site.

Usability testing involves following main steps
· identify the website's purpose;
· identify the indented users ;
· define tests and conduct the usability testing
· analyze the acquired information

3. Navigation Testing
Good Navigation is an essential part of a website, especially those that are complex and provide a lot of information. Assessing navigation is a major part of usability Testing.

4. Forms Testing
Websites that use forms need tests to ensure that each field works properly and that the forms posts all data as intended by the designer.

5. Page Content Testing
Each web page must be tested for correct content from the user perspective for correct content from the user perspective. These tests fall into two categories: ensuring that each component functions correctly and ensuring that the content of each is correct.

6. Configuration and Compatibility testing
A key challenge for web applications is ensuring that the user sees a web page as the designer intended. The user can select different browser software and browser options, use different network software and on-line service, and run other concurrent applications. We execute the application under every browser/platform combination to ensure the web sites work properly under various environments.

7. Reliability and Availability Testing
A key requirement o a website is that it Be available whenever the user requests it, after 24-hours a day, every day. The number of users accessing web site simultaneously may also affect the site's availability.

8. Performance Testing
Performance Testing, which evaluates System performance under normal and heavy usage, is crucial to success of any web application. A system that takes for long to respond may frustrate the user who can then quickly move to a competitor's site. Given enough time, every page request will eventually be delivered. Performance testing seeks to ensure that the website server responds to browser requests within defined parameters.

9. Load Testing
The purpose of Load testing is to model real world experiences, typically by generating many simultaneous users accessing the website. We use automation tools to increases the ability to conduct a valid load test, because it emulates thousand of users by sending simultaneous requests to the application or the server.

10. Stress Testing
Stress Testing consists of subjecting the system to varying and maximum loads to evaluate the resulting performance. We use automated test tools to simulate loads on website and execute the tests continuously for several hours or days.

11. Security Testing
Security is a primary concern when communicating and conducting business- especially sensitive and business- critical transactions - over the internet. The user wants assurance that personal and financial information is secure. Finding the vulnerabilities in an application that would grant an unauthorized user access to the system is important.

2 comments:

  1. Thanks for your effort and publish such a great article regarding QTP. Hope you will get success in this industry. Keep it up...

    ReplyDelete
    Replies
    1. thank paresh i"ll try to post such a good artical regarding testing domain

      Delete