• Skip to main content
  • Skip to primary sidebar
  • Skip to footer
  • Home
  • Programming Languages
    • Java Tutorials
    • Python Tutorials
    • JavaScript Tutorials
  • Automation Tools and Different Tools
    • Web Automation
      • Selenium with Java
        • Selenium Basic
        • Selenium Advance
        • Selenium Realtime
        • Framework
        • Selenium Interview
        • Selenium Videos
        • Selenium with Docker
      • Selenium with Python
      • WebdriverIO
        • Selenium Webdriver C# Tutorial
      • Cypress
      • Playwright
    • TestNG
    • Cucumber
    • Mobile Automation
      • Appium
    • API Testing
      • Postman
      • Rest Assured
      • SOAPUI
    • testRigor
    • Katalon
    • TestProject
    • Serenity BDD
    • Gradle- Build Tool
    • RPA-UiPath
    • Protractor
    • Windows Automation
  • Automation For Manual Testers
  • Services
  • Online Training
  • Contact us
  • About me
  • Follow us
    • Linkedin
    • Facebook Group
    • Facebook Page
    • Instagram

Automation

Selenium WebDriver tutorial Step by Step

You are here: Home / Advance Selenium / Most Common Challenges You Faced in Selenium Automation

Most Common Challenges You Faced in Selenium Automation

April 14, 2020 by Mukesh Otwani 13 Comments

Most Common Challenges You Faced in Selenium Automation

Selenium is an open-source test automation framework and it has its own advantage and disadvantage as well. Even if you take other automation tools like QTP, Katalon, Sahi, etc every single tool has some kind of limitation. Today I am going to discuss some challenges which we face in our day to day activity. The most common challenges you faced in Selenium Automation might defer.

Most Common Challenges You Faced in Selenium Automation

You can also add a few more challenges based on your previous/current experience but below listed one common for each and everyone in Test Automation.

Challenges Faced In Selenium Webdriver In Automation

 

Sync issue or Timeout

Sync issue or I would say timeout issue is one of the most challenging tasks in any test automation tool. If we do not handle sync issue then most of the script will fail. In one of the test surveys, it has found that 80% of scripts fail due to improper sync while performing actions.

We can avoid this by using smart wait which is present in Selenium like implicit wait, explicit wait, fluent wait or even you can write your custom method which will handle these sync issues.

Example– After clicking on some button one alert should present and we have to handle via code but due to many issues alert might come after a few seconds, in that case, the script will fail. We need to handle this kind of scenario using an explicit wait. This is just one example like this we have many examples which show without a smart locator we cannot build stable scripts.

 

Integration with different tools

Since Selenium is open-source and we all are using many open source tools like Maven, Jenkins, AutoIT, etc. so integration between these tools is sometimes a very challenging task.

 

Smart locators

As we all know that locators are the core part of any scripting and we need to keep on enhancing our XPath and CSS for script stability, because if XPath and CSS are not proper then chances are very hight that script might fail in upcoming releases.

We should always write dynamic or custom XPath or class, which can make our script more stable.

Cross browser testing

While designing script we always focus on one browser and we design our script for that browser only, but when it comes to real execution of the script then we have to make sure that our script should run in all browser which is known as Cross Browser Testing (Chrome, FF, IE at least). I had been struggling with this topic , because few locators will work in one browser but not on the other. In order to avoid failure once the script is developed we need to run them on the different browsers and analyse the result. If it is failing on another browser then we need to change locator strategy.

Nowadays we have many cloud companies like SauceLab, BrowserStack etc which provide as complete infrastructure like Windows, MAC, Linux with different browser combinations as well, so if our script is compatible with all then it will be easy for us to run on the cloud.

 

Framework Enhancement & Maintenance

We always work for the framework but framework designing and maintenance is not a one-day activity, we have to keep on adding new features or libraries so that we can minimize execution time and maintenance task.

 

Pop up handling

In many applications, you will find random pop that keeps coming and their behaviour is not persistent, so we also have to take care of these unwanted pop up which stops our execution.

Complex Programming

Selenium support multiple languages and in order to work we should know at least one programming language so in order to build a framework we need some expertise in a specific language.

Lack of Transparency

Few companies or I would say many companies they do not follow proper code review which can create many issues in the future.

Example- Code review includes code formatting, proper validation or assertion, effective usage of the framework, the design pattern used and so on.

That’s all I have from my side, whatever challenges you have faced in your organization or in your current role feel free to comment below. I would love to hear from you.

 

I hope this article helped you. If yes then kindly share with your friends and follow me on my Youtube channel as well.

Filed Under: Advance Selenium Tagged With: Most common challenges you faced in Selenium Automation

Reader Interactions

Comments

  1. Bibhas says

    March 20, 2019 at 1:41 PM

    Hi Mukesh,
    Need your help as always. I have one BasicHttpBidingServices that I need to automate.Manually I test each request with authentication in SoapUI5.3.0.Each binding has almost 10 requests.So I want to automate like- for 10 request scripts in the binding tree should be triggered at a time or one by one where we need to change the request parameter externally.

    Please provide some solution on this.This is for WebServices only not for REST.

    Reply
    • Mukesh Otwani says

      March 20, 2019 at 1:57 PM

      Hi Bibhas this will be data driven test for SOAPUI, please check below link which will give idea https://www.soapui.org/docs/data-driven-tests/using-files.html

      Reply
      • Bibhas says

        March 20, 2019 at 4:24 PM

        Hi Mukesh,
        I don’t have license version of SOAP that is why want to automate using Selenium. Is there any way to automate.

        Reply
        • Mukesh Otwani says

          March 21, 2019 at 12:11 PM

          Hi Bibhas,

          Selenium only automate WebBrowser so we need to take help of third party library or custom Java code.
          In Java we have HTTPURLConnection class which can automate Rest and SOAP both. You can get reference from below link https://www.journaldev.com/7148/java-httpurlconnection-example-java-http-request-get-post

          Reply
  2. Reshma Patil says

    February 9, 2019 at 8:56 PM

    Hi Mukesh,

    I am currently automating SAP web based system.
    When i m trying to click on a particular element its opening a new window everytime.
    I tried switching window with the current syntax and when i try entering values on new opened window its giving me errors like unable to locate the element.
    I found the xpath on chrome browser its highlighting the element correctly in chrome but when I add in my code its not working. Tried maximum possible xpaths but its not working for me.
    Could you please help

    Reply
    • Mukesh Otwani says

      February 9, 2019 at 9:59 PM

      Hi Reshma,

      Looks like you are able to switch to new window. Then you need to check whether target webelement is lying on some frame or not.

      Reply
    • Reshma Patil says

      February 10, 2019 at 10:22 AM

      I tried inserting sikuli and its working fine but for selenium its still not working.

      Reply
      • Mukesh Otwani says

        February 11, 2019 at 10:38 AM

        Hi Reshma,

        Good…
        Selenium has its own limitations that is why we require to use third party tools to achieve our task.

        Reply
  3. sean paul says

    December 30, 2018 at 8:00 PM

    alert(“Getting life!”)

    Reply
    • Mukesh Otwani says

      January 2, 2019 at 3:52 PM

      driver.switchTo().alert().accept();

      Reply
  4. Tanu says

    December 12, 2018 at 4:39 PM

    yes code review is one of the serious problem ……

    Reply
  5. karthik babu says

    November 29, 2018 at 8:51 AM

    Brief and precise note on all the challenges. Nice write up

    Reply
    • Mukesh Otwani says

      November 29, 2018 at 9:32 AM

      Hi Karthik,

      Thanks….:)

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Free Selenium Videos

https://www.youtube.com/watch?v=w_iPCT1ETO4

Search topic

Top Posts & Pages

  • Selenium Webdriver tutorial for beginners
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Selenium Webdriver C# Tutorial
  • WHAT ARE YOUR EXPECTATIONS FROM US?

Stay connected via Facebook

Stay connected via Facebook

Archives

Footer

Categories

Recent Post

  • API Testing Using Postman And RestAssured
  • Disable Personalise Your Web Experience Microsoft Edge Prompt In Selenium
  • How To Fix Error: No tests found In Playwright
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Best and easy way to Group test cases in selenium

Top Posts & Pages

  • Selenium Webdriver tutorial for beginners
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Selenium Webdriver C# Tutorial
  • WHAT ARE YOUR EXPECTATIONS FROM US?