Image
Blog Banner Image

Best practices for Testing Web Applications

Deepa Prajapati
June 12, 2020

In the current situation, numerous Web applications are emerging in technologies such as mobile, social media, and cloud. Every hour hundreds of new websites and web-based applications are launched. For this kind of increasing requirement quality testing of Web-applications has become crucial. Also, Cloud technologies are evolving rapidly and changing the way we do business today. It is not enough to just have functional systems and integrations in the cloud, but their performance, usability, security, etc. also bear equal importance. Learn more about Enterprise application testing

To overcome most of the hurdles in the testing of web applications, testing teams can implement some of the best practices as described below.

A. Focus on cross-browser and Compatiblity Testing

  1. Why is it important?

    There are many instances where we come across issues like –

    • Global search is not working on iPhone, iPad, and older Android phones
    • Banner images are not moving on Firefox 3.
    • Tables don’t load completely on small screen mobile devices
    • HTML tags are not supported on Chrome 71

    Such defects mostly arise from cross-browser testing. With the easy availability of a variety of browsers with their various versions, mobile phones, tablets, and so many other gadgets, it has become inevitable for companies to make their web applications available on many of them, if not all.

    It is also important to give the same user-experience across all browsers/devices. Of course, a web-application would look and work slightly different on a browser than on a mobile app, but we need to maintain similarity in its core features such as fonts, colors, backgrounds, popups, layouts, etc. on most of the browsers and devices. Without compatibility testing, your web-application may show up noticeable differences and issues across different devices/browsers which may prove your application to be unreliable and unprofessional.

  2. How it’s done?

    Testing teams are required to strategically plan their test scenarios and activities for cross-browser and compatibility testing because this kind of testing can be one of the most tedious kinds, especially for manual testers. You need to first finalize the scope – like what devices, browsers, gadgets, tools, systems – your application should be compatible with. Also, when you compare your application running on different devices/browsers you are actually looking for a comparison between different rendering engines. This helps you in deciding where and what kind of fixing is required.

    Cross-browser testing or Compatibility testing can be done manually or with the help of automation tools. Although, some key questions you may want to ask before selecting a manual or automation approach for testing your application’s compatibility would be:

    • How complex is your web application/website?
    • How many browsers you want your application/site to support?
    • How many versions of each browser you want your application/site to support?
    • How many devices you want your application/site to support?
    • How many operating systems you want your application/site to support?
    • What is your scope of performance on each device/browser?

    This kind of testing is repetitive and hence, usually, automation is more preferable and cost-effective. Once you can answer the above questions you simply have to design your test plans and start testing using the standard techniques on each browser/device in the picture: Sanity tests, Functional tests, Regression tests to verify:

    • HTML validation
    • CSS validation
    • Page validations
    • Ajax related features
    • Font size validation
    • Page layout in different resolutions, etc.

B. Consider usablity as the next most Important factor

  1. Why is it important?

    Usability testing is a Black Box testing technique in which testing is done with end-users point of view. It is done to determine how easy it is for the users to use the software application in various conditions. Imagine an application that is so complex for the users that it takes hours of training on simple functions and hundreds of questions after that. Usability testing is done to ensure that the end-user finds all items/functions in the applications easy to understand and use.

    Nobody wants to spend time in lengthy training and demos, instead, people want simple and easy-to-use applications. If you take an example of social media apps or e-commerce websites trending these days, you will notice that they are designed for all categories of people, with any kind of background and even with least knowledge of technology. Users are doing various activities on social media and buying from shopping sites. That’s the whole point of usability. Companies need to understand that a website’s usability directly impacts user experience and satisfaction, which further impacts the company’s reputation and business.

  2. How it’s done?

    Generally, usability planning is done through research, surveys, or comparisons. Users are asked to go through the website pages and see how user-friendly and self-explanatory each area on the website is. Sometimes, a survey is done to find what people would like to have a particular kind of website or application. Or in other cases, doing some research on existing applications of the same domain and comparing what looks and feels best, also helps in finalizing your application’s usability requirements.

    Key areas to check in usability testing:

    User-Friendliness

    • Application is easy-to-use and navigates through
    • Every control on the application is self-explanatory
    • It doesn’t require a lot of training, but help documents are provided on necessary places

    Accuracy

    • The application provides all correct and up-to-date data
    • There are no broken links

    Accessibility

    • Website’s loading time and rendering time is reasonable
    • GUI of the application is as per the domain standards

C. Your application needs to "Perform" Well

  1. Why is it important?

    Is this even a question? What is an application of any use if it does not perform well? Who has time nowadays to keep waiting for pages to load and reports to generate? Researchers claim that most users will lose interest after 8 seconds of delay. Every year around 4.4 billion-dollar revenue is lost due to poor performing web-applications. Is there a need to say more?

    Sometimes minor flaws in the system can affect the website’s performance severely. Therefore, it is required to perform load testing and evaluate how the application performs under varying loads.

  2. How it’s done?

    Performance testing is usually done to Investigate, measure, or verify Scalability, Reliability, and Resource usage. It is a measure of – Concurrency/Throughput, Server response time, Render-response time, Load Testing, Endurance Testing

    Some high-level steps, which can be used for both manual as well as automation, to do performance testing on your application are:

    1. Analyze project requirements
    2. Identify Performance testing requirements
    3. Plan and design your tests
    4. Execute tests
    5. Report and Retest

 

D. Validate and maintain application's Security

  1. Why is it important?

    Even in these times when cybercrimes are emerging frequently, the application’s security is overlooked by many companies. Your software meeting quality, functional, and performance requirements are not enough. In today’s era where online banking, payments, social media, etc. which deal with money or your personal information, how would you like web-applications that leak such data?

    In 2017 CSI Computer Crime and Security Survey performed an analysis of the average cost of a web security breach. 46% of all businesses have identified at least one cybersecurity breach or attack in the year, not to mention billions of dollars that are lost worldwide in cybercrimes. Read relevant blog here: Mobile Application Testing: Challenges and Solutions

  2. How it’s done?

    The best way to ensure application security is that its development life cycle processes should rigorously conform to secure development, deployment, and maintenance principles and practices. The two major aspects of security testing are protection of data and access to that data. If unauthorized access is granted to protected data, then it’s a security breach. Below steps can be used to perform Security testing of your application:

    1. Password splitting:

      Some of the authentication tests include a test for password quality rules, test for default logins, test for password recovery, test captcha, test for logout functionality, test for password change, test for security question/answer, etc. In short, password security is one of the most basic and important things to consider in Security testing.

    2. URL Manipulation :

      The HTTP GET method query string parameters can be modified by testers in order to check if the server accepts it. The method generally used by hackers is to change a parameter value in the querystring, which would cause unintended behavior by the server. A security tester can do the same to see if the server accepts it.

    3. SQL Injection:

      If the tester encounters database errors while testing, it means that the application is vulnerable to SQL injections. Entering single quote (‘) in text fields of the application should be prohibited in order to protect the data in your databases. Moreover, all input fields in your application should have maximum lengths implemented.

    4. Cross Site Scripting (XSS):

      In this method, security testers can validate if XSS scripting is accepted by the application. For example, tags like HTML or SCRIPT should not be accepted by the application, else the application will be prone to Cross Site Scripting attacks.

Conclusion

Even with all these best practices, Functional and Regression testing of the application should not be overlooked. But of course, some companies always focus on these two and neglect all the rest. Faulty and defective web applications not only look unreliable but adversely affect the business efforts leading to increased costs and loss of business reputation. By following the aforementioned practices for testing web-applications, businesses can significantly reduce their risks and deliver best quality apps.

About the Author

Deepa Prajapati

Deepa is a QA Team Lead. She has 10+ years of experience in the Software Testing field. Most of her experience lies in Functional Testing, Agile and ServiceNow.

Add New Comment

Restricted HTML

  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id>
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.