Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Testcafe with SmartClient

    Has anyone tried using Testcafe (NodeJS) to test SmartClient. We are on an older version of SmartClient and Selenium support was iffy to begin with. Now it is pretty outdated using the Selenium IDE 2 version and Firefox version 52 I believe (old!).

    I tried taking the Selenium IDE extension files and pulling out a function to try to grab the locators so Testcafe could get ahold of them. But no luck. Just get weird errors. Code that runs on other pages just bombs out on SmartClient pages in our app because all the locators are obfuscated as the Isomorphic folks always mention in posts and documentation. The functions to try to grab them do not seem to help at all. In fact even functions in Testcafe to grab the window do not work.

    Any guidance or help would be appreciated. We have gone a good 3-4 years now without automated testing since the Selenium IDE stopped working with our code and the SC Selenium IDE extensions for version 10. We have a large enterprise application and being able to get some automation testing going again would be a great help.

    Thanks in advance. I know this is kind of vague. I am just looking for directions to pieces of code and things that would help with this. I am willing to write something that will work in Testcafe and do it from scratch. But something has to grab the pieces out of SC so we can work with them.


    #2
    See the Automated Testing overview - you don't need the Selenium IDE to acquire locators, you can simply get them from the Developer Console and/or programmatically. Then you can use them with whatever test tool you like, but Selenium / WebDriver is going to be easiest by far; with those environment, we've already worked around all the issues that can come from incompletely simulated events (eg test frameworks that just send click without doing a proper mouseDown/mouseUp etc sequence).

    Also, it doesn't make sense to start building an automated test suite for an application built on an outdated version of SmartClient. You'll want to update to the latest first.

    Comment


      #3
      We are stuck on version 10 for the moment. We plan to upgrade. But it makes sense to do a happy-path automated test for application since it is so large. Plus with moving to a new version the basics should stay the same, buttons, tabs etc.

      I know the names of our elements like button='ok'. Have tried adding ID numerous times but that gets sucked out by SmartyClient always.
      So trying to hit elements by name with most tools like Testcafe that have their own way of finding selectors by ID does not work.

      This is why we have not upgraded, and why we may not sell it to management to do the upgrade. Without being able to do some automation testing our massive enterprise app requires a lot of manual QC time. Wish you all would consider a 'switch' to turn obfuscation of IDs on/off.



      Comment


        #4
        So you are stuck using a tool that is totally unable to customize how it looks up DOM elements, programmatically or otherwise? That would be really bad if true - we've seen a few organizations that had irrational attachment to one particular tool and couldn't use Selenium, but we've never seen such a tool be mandated and found that it wasn't even customizable in this key way. Perhaps worth double-checking.

        If TestCafe is indeed that limited, we could, through Feature Sponsorship, add some workarounds for your tool. However, that doesn't really help because:

        1. it wouldn't be a truly supported approach anyway, because the DOM is intentionally undocumented, because it needs to vary by browser and browser version to work around browser bugs, and also needs to be changed without notice to work around new browser bugs when they arise. That's why we have the locator system - so we can provide stable addressing of DOM elements

        2. you're stuck on version 10 anyway, and sponsorships are only for the latest version

        Comment

        Working...
        X