Selenium



  • We write tests for our software. This, I think, is a major point for us. While the other teams on our project are content testing mocks of the mocks of their code and having offshore QA manually test everything, we take the approach of automating anything we can.

    Unfortunately, while we could have probably done this whole project in half the time with just ASP.NET and basic knockout or something, we use Angular. Not only that, we generate angular pages on the fly with proprietary nonsense some of the people who made all the decisions on this project (and then left) developed for a previous product.

    So ultimately we need to test some UI, and that basically means Selenium. After all, it's a high-quality open source project that everyone uses, right?

    Well it turns out, Selenium is made by morons. The driver usually works as intended on Chrome, but behaves substantially different on every browser. On Firefox and Edge, asking the webdriver to wait for something to load does nothing: it immediately continues and fails, saying it couldn't find the next thing. If you construct page objects, Chrome runs tests substantially faster, but the others don't. IE expects specific security settings that our IT keeps changing, and lately has been ignoring click requests, or in some cases, doubling any input you ask it to send. Meanwhile Edge, whose driver Microsoft themselves make, only works with the nuget package corresponding to the version of edge your version of Windows contains, and is not backward compatible.

    So, any prospective web devs beware: You are attempting to enter the worst part of an industry with more than its fair share of problems.


  • SockDev

    @magus said in Selenium:

    You are attempting to enter the worst part of an industry with more than its fair share of problems.

    and the worst part? seleneum doesn't have any strong competitors, or if it does they're doing a fooking fantastic job of keeping it on the down low.



  • @accalia It isn't possible for them to have strong competitors. Any competitors at all could blow them out of the water.


  • SockDev

    @magus said in Selenium:

    @accalia It isn't possible for them to have strong competitors. Any competitors at all could blow them out of the water.

    sounds like a business opportunity for you.

    :-)



  • @accalia I'm not getting javascript on me.


  • SockDev

    @magus said in Selenium:

    @accalia I'm not getting javascript on me.

    ah.

    okay.

    maybe someone else will want to make the world a better place and make a wad of dosh doing it.

    :-P


  • SockDev

    @magus said in Selenium:

    @accalia I'm not getting javascript on me.

    Write it in TypeScript maybe?



  • @accalia Even if you could make the world a better place with a piece of web software, you'd have to market it to people who think git and npm are paragons of good software design.


  • I survived the hour long Uno hand

    @magus said in Selenium:

    . On Firefox and Edge, asking the webdriver to wait for something to load does nothing: it immediately continues and fails, saying it couldn't find the next thing.

    What? This has never happened to me. What does your wait look like? Usually Firefox is the best supported, as that's the browser the Selenium devs use.

    @magus said in Selenium:

    IE expects specific security settings that our IT keeps changing, and lately has been ignoring click requests, or in some cases, doubling any input you ask it to send.

    This, sadly, 100% matches my experience.



  • @yamikuronue We just used the webdriver's waitforelement methods and such. I don't know if they just don't use C# to write their tests in, but yeah, Firefox just ignored all our requests that it wait, and we had to use Thread.Sleep in places.


  • I survived the hour long Uno hand

    @magus The Selenium team definitely use the Java bindings, they're the best maintained. That's just weird though.



  • @magus said in Selenium:

    @accalia I'm not getting javascript on me.

    Emscripten!



  • @magus said in Selenium:

    @yamikuronue We just used the webdriver's waitforelement methods and such. I don't know if they just don't use C# to write their tests in, but yeah, Firefox just ignored all our requests that it wait, and we had to use Thread.Sleep in places.

    From what I gather of my QA team's chatter, they have similar problems - there's a lot of Thread.Sleep peppered over the test project, and any given test run usually fails at least a bunch of the tests, which then need to be individually re-ran.


  • BINNED

    @maciejasjmj said in Selenium:

    @magus said in Selenium:

    @yamikuronue We just used the webdriver's waitforelement methods and such. I don't know if they just don't use C# to write their tests in, but yeah, Firefox just ignored all our requests that it wait, and we had to use Thread.Sleep in places.

    From what I gather of my QA team's chatter, they have similar problems - there's a lot of Thread.Sleep peppered over the test project, and any given test run usually fails at least a bunch of the tests, which then need to be individually re-ran.

    Pretty much what I've seen with the Selenium based testing tool I inherited. There's an extension method in this thing that wraps the waitfor in a loop of sleeps to get around it, and it was originally Firefox only



  • @accalia said in Selenium:

    @magus said in Selenium:

    You are attempting to enter the worst part of an industry with more than its fair share of problems.

    and the worst part? seleneum doesn't have any strong competitors, or if it does they're doing a fooking fantastic job of keeping it on the down low.

    Shameless plug: A research colleague of mine developes a "visual test automation" application called EyeStudio that may be a useful competitor:

    ... but seeing that they also have a Selenium plugin, then maybe not.

    TL;DR: You create a test script based on screenshots of the buttons, text areas or images to interact with.


  • BINNED

    @mikael_svahnberg said in Selenium:

    EyeStudio

    This looks pretty good, and may make the tool I've been working on in downtime to make testers' lives easier a bit redundant if I can get buyin. Thanks for the suggestion



  • @accalia said in Selenium:

    a wad of dosh

    Is that what the kids are calling it these days?


  • SockDev

    @boomzilla said in Selenium:

    @accalia said in Selenium:

    a wad of dosh

    Is that what the kids are calling it these days?

    dunno. i don't hang out with kids much anymore because @Perverted_Vixen keeps stopping by and there's nothing like the fury of an outrages parent........


  • area_can

    @boomzilla said in Selenium:

    @accalia said in Selenium:

    a wad of dosh

    Is that what the kids are calling it these days?

    \/ /\


  • :belt_onion:

    @mikael_svahnberg said in Selenium:

            EyeStore
    

    0_1503544693138_328178a2-cc11-4f76-97e2-005e1ec878c9-image.png

    oh wait... that's actually part of their background image, not a real search input. :wtf: designed that
    quite an eyesore.


  • :belt_onion:

    @accalia said in Selenium:

    dunno. i don't hang out with kids much anymore because @Perverted_Vixen keeps stopping by and there's nothing like the furry of an outrageous parent........

    ftfy


Log in to reply
 

Looks like your connection to What the Daily WTF? was lost, please wait while we try to reconnect.