Alternatives to jsdom logo

Alternatives to jsdom

Selenium, PhantomJS, Enzyme, Domino, and Puppeteer are the most popular alternatives and competitors to jsdom.
604
50
+ 1
1

What is jsdom and what are its top alternatives?

It is a pure-JavaScript implementation of many web standards, notably the WHATWG DOM and HTML Standards, for use with Node.js. In general, the goal of the project is to emulate enough of a subset of a web browser to be useful for testing and scraping real-world web applications.
jsdom is a tool in the Headless Browsers category of a tech stack.
jsdom is an open source tool with 18.8K GitHub stars and 1.6K GitHub forks. Here’s a link to jsdom's open source repository on GitHub

Top Alternatives to jsdom

  • Selenium
    Selenium

    Selenium automates browsers. That's it! What you do with that power is entirely up to you. Primarily, it is for automating web applications for testing purposes, but is certainly not limited to just that. Boring web-based administration tasks can (and should!) also be automated as well. ...

  • PhantomJS
    PhantomJS

    PhantomJS is a headless WebKit scriptable with JavaScript. It is used by hundreds of developers and dozens of organizations for web-related development workflow. ...

  • Enzyme
    Enzyme

    Enzyme is a JavaScript Testing utility for React that makes it easier to assert, manipulate, and traverse your React Components' output. ...

  • Domino
    Domino

    Use our cloud-hosted infrastructure to securely run your code on powerful hardware with a single command — without any changes to your code. If you have your own infrastructure, our Enterprise offering provides powerful, easy-to-use cluster management functionality behind your firewall. ...

  • Puppeteer
    Puppeteer

    Puppeteer is a Node library which provides a high-level API to control headless Chrome over the DevTools Protocol. It can also be configured to use full (non-headless) Chrome. ...

  • Playwright
    Playwright

    It is a Node library to automate the Chromium, WebKit and Firefox browsers with a single API. It enables cross-browser web automation that is ever-green, capable, reliable and fast. ...

  • CasperJS
    CasperJS

    CasperJS is a browser navigation scripting & testing utility written in Javascript for PhantomJS or SlimerJS. ...

  • Splash
    Splash

    It is a headless browser that executes JavaScript for people crawling websites. It is open source and fully integrated with Scrapy and Portia. You can also use its API to integrate with any project that needs to render JavaScript pages. ...

jsdom alternatives & related posts

Selenium logo

Selenium

14.2K
11.5K
523
Web Browser Automation
14.2K
11.5K
+ 1
523
PROS OF SELENIUM
  • 173
    Automates browsers
  • 154
    Testing
  • 101
    Essential tool for running test automation
  • 24
    Record-Playback
  • 24
    Remote Control
  • 8
    Data crawling
  • 7
    Supports end to end testing
  • 6
    Functional testing
  • 6
    Easy set up
  • 4
    The Most flexible monitoring system
  • 3
    End to End Testing
  • 3
    Easy to integrate with build tools
  • 2
    Comparing the performance selenium is faster than jasm
  • 2
    Record and playback
  • 2
    Compatible with Python
  • 2
    Easy to scale
  • 2
    Integration Tests
  • 0
    Integrated into Selenium-Jupiter framework
CONS OF SELENIUM
  • 8
    Flaky tests
  • 4
    Slow as needs to make browser (even with no gui)
  • 1
    Update browser drivers

related Selenium posts

Kamil Kowalski
Lead Architect at Fresha · | 28 upvotes · 2M views

When you think about test automation, it’s crucial to make it everyone’s responsibility (not just QA Engineers'). We started with Selenium and Java, but with our platform revolving around Ruby, Elixir and JavaScript, QA Engineers were left alone to automate tests. Cypress was the answer, as we could switch to JS and simply involve more people from day one. There's a downside too, as it meant testing on Chrome only, but that was "good enough" for us + if really needed we can always cover some specific cases in a different way.

See more
Benjamin Poon
QA Manager - Engineering at HBC Digital · | 8 upvotes · 1M views

For our digital QA organization to support a complex hybrid monolith/microservice architecture, our team took on the lofty goal of building out a commonized UI test automation framework. One of the primary requisites included a technical minimalist threshold such that an engineer or analyst with fundamental knowledge of JavaScript could automate their tests with greater ease. Just to list a few: - Nightwatchjs - Selenium - Cucumber - GitHub - Go.CD - Docker - ExpressJS - React - PostgreSQL

With this structure, we're able to combine the automation efforts of each team member into a centralized repository while also providing new relevant metrics to business owners.

See more
PhantomJS logo

PhantomJS

516
426
18
Scriptable Headless WebKit
516
426
+ 1
18
PROS OF PHANTOMJS
  • 13
    Scriptable web browser
  • 3
    Depends on QT
  • 2
    No ECMAScript 6
CONS OF PHANTOMJS
    Be the first to leave a con

    related PhantomJS posts

    Tim Abbott

    We use CasperJS because we adopted it back in 2013 for JavaScript frontend testing. It was a really nice system back then compared to what else was out there; you had PhantomJS as a programmable browser that actually rendered CSS and everything, it was really fast (speed is a big downside of e.g. Selenium), and it was possible to make non-flaky frontend integration tests with it.

    I wouldn't recommend it today, because PhantomJS is a basically dead project, and as a result, so is CasperJS. I expect we'll migrate to something else. We haven't in large part because 95% of our new tests are written with a simple Node.js-based unit testing framework we use that run 35K lines of unit tests covering most of our JS codebase in 3.6 seconds. And for the things where we want an integration test, CasperJS does work, and I think there's a good chance that waiting another year or two will result in our being able to switch to a much better option than what we'd get if we migrated now.

    See more
    Enzyme logo

    Enzyme

    456
    346
    0
    JavaScript Testing utilities for React, by Airbnb
    456
    346
    + 1
    0
    PROS OF ENZYME
      Be the first to leave a pro
      CONS OF ENZYME
        Be the first to leave a con

        related Enzyme posts

        Russel Werner
        Lead Engineer at StackShare · | 7 upvotes · 168.6K views

        We use Jest because when we rebooted our "front end" stack earlier last year, we need to have a testing solution (we didn't have any front-end tests before that!). Jest is fast and convenient and it has plenty of community support behind it. It let's us run our unit tests with Enzyme and snapshot tests.

        This is an area that we are constantly reviewing to see what can be improved, both in terms of developer needs, accuracy, test maintainability, and coverage.

        I'm currently exploring using React Storybook to be the record of snapshot tests and using some online services, such as Happo.io and Percy in our CI pipeline.

        See more

        I use both mocha and Jest because:

        • I don't care whether teams use Jest or Mocha. But jest is way too overhyped. Most devs are writing integration tests and think that it's so much better but frankly I don't write integration tests as the way to get both design feedback and confidence when I code. I adhere to the test pyramid, not ice cream cone or the dumb "trophy"

        • I TDD, so I only ever use the "API" of test frameworks. I don't do a lot of integration tests for TDD and all the bells and whistles Jest provides you from the command-line I just don't need. And I certainly do not care about or touch Jest Snapshots, I despise them

        • My tests are fast enough because I write isolated tests with TDD, so I don't run into performance issues. Example: I write my tests in a way that I can run 300 tests in literally 1 second with mocha. So the Jest ability to pinpoint and only run those tests which are affected by code changes. I want to run all of them every time when I TDD. It's a different mindset when you TDD

        • I also mainly code in IntelliJ or WebStorm because I feel the tools in that IDE far surpass VSCode and I also love running the test UI runner in it vs. lousy command-line

        • I feel both mocha and Jest read just fine in terms of code readability. Jest might have shorter assertion syntax but I don't really care. I just care that I can read the damn test and my tests are written well and my test descriptions, as well as the code itself including constants represent business language, not technical. I care most about BDD, clean code, 4 rules of simple design, and SOLID

        • I don't like using mock frameworks so no I don't use Jest's Mocking framework. I don't have to mock a lot in my tests due to the nature of how I strive to code...I keep my design simple and modular using principals such as clean code and 4 rules of simple design. If I must mock, I create very simple custom mocks with JS

        • On the contrary to the belief that integration tests and mount are the way to go (this belief drives me absolutely crazy, especially Dodd's promoting that), I TDD with shallow & enzyme. My tests are simple. My design is driven by my tests and my tests give me quick and useful feedback. I have a course I'm working on coming out soon on TDD with React to show you how to truly test the FE and why the ice cream cone and trophy suck (you're being scammed people). Watch for that here: https://twitter.com/DaveSchinkel/status/1062267649235791873

        Don't forget to upvote this post!

        Mocha Jest JavaScript React @jsdom Enzyme #tdd #bdd #testdrivendevelopment

        See more
        Domino logo

        Domino

        19
        29
        0
        A PaaS for data science - easily run R, Python or Matlab code in the cloud with automatic...
        19
        29
        + 1
        0
        PROS OF DOMINO
          Be the first to leave a pro
          CONS OF DOMINO
            Be the first to leave a con

            related Domino posts

            Puppeteer logo

            Puppeteer

            384
            554
            26
            Headless Chrome Node API
            384
            554
            + 1
            26
            PROS OF PUPPETEER
            • 10
              Very well documented
            • 10
              Scriptable web browser
            • 6
              Promise based
            CONS OF PUPPETEER
            • 10
              Chrome only

            related Puppeteer posts

            Raziel Alron
            Automation Engineer at Tipalti · | 7 upvotes · 359.6K views

            Currently, we are using Protractor in our project. Since Protractor isn't updated anymore, we are looking for a new tool. The strongest suggestions are WebdriverIO or Puppeteer. Please help me figure out what tool would make the transition fastest and easiest. Please note that Protractor uses its own locator system, and we want the switch to be as simple as possible. Thank you!

            See more

            I work in a company building web apps with AngularJS. I started using Selenium for tests automation, as I am more familiar with Python. However, I found some difficulties, like the impossibility of using IDs and fixed lists of classes, ending up with using xpaths most, which unfortunately could change with fixes and modifications in the code.

            So, I started using Puppeteer, but I am still learning. It seems easier to find elements on the webpage, even if the creation and managing of arrays of elements seem to be a little bit more complicated than in Selenium, but it could be also due to my poor knowledge of JavaScript.

            Any comments on this comparison and also on comparisons with similar tools are welcome! :)

            See more
            Playwright logo

            Playwright

            273
            470
            76
            Node library to automate Chromium, Firefox and WebKit with a single API (By Microsoft)
            273
            470
            + 1
            76
            PROS OF PLAYWRIGHT
            • 13
              Cross browser
            • 10
              Open source
            • 9
              Test Runner with Playwright/test
            • 7
              Well documented
            • 7
              Promise based
            • 5
              Integrate your POMs as extensible fixtures
            • 5
              API Testing
            • 5
              Execute tests in parallel
            • 4
              Capture videos, screenshots and other artifacts on fail
            • 4
              Python Support
            • 3
              Context isolation
            • 3
              Inbuild reporters html,line,dot,json
            • 1
              Fastest
            CONS OF PLAYWRIGHT
            • 11
              Less help
            • 3
              Node based
            • 1
              Does not execute outside of browser

            related Playwright posts

            Lily Goykhman
            Engineering management at SB · | 3 upvotes · 7.8K views
            Shared insights
            on
            PlaywrightPlaywrightPuppeteerPuppeteer

            Test automation - Puppeteer is used currently, just rudimentary stuff, but considering the better choices with Playwright?

            See more
            CasperJS logo

            CasperJS

            60
            119
            0
            Navigation scripting & testing for PhantomJS and SlimerJS
            60
            119
            + 1
            0
            PROS OF CASPERJS
              Be the first to leave a pro
              CONS OF CASPERJS
                Be the first to leave a con

                related CasperJS posts

                Tim Abbott

                We use CasperJS because we adopted it back in 2013 for JavaScript frontend testing. It was a really nice system back then compared to what else was out there; you had PhantomJS as a programmable browser that actually rendered CSS and everything, it was really fast (speed is a big downside of e.g. Selenium), and it was possible to make non-flaky frontend integration tests with it.

                I wouldn't recommend it today, because PhantomJS is a basically dead project, and as a result, so is CasperJS. I expect we'll migrate to something else. We haven't in large part because 95% of our new tests are written with a simple Node.js-based unit testing framework we use that run 35K lines of unit tests covering most of our JS codebase in 3.6 seconds. And for the things where we want an integration test, CasperJS does work, and I think there's a good chance that waiting another year or two will result in our being able to switch to a much better option than what we'd get if we migrated now.

                See more
                Splash logo

                Splash

                27
                33
                0
                Headless browser that executes JavaScript for people crawling websites
                27
                33
                + 1
                0
                PROS OF SPLASH
                  Be the first to leave a pro
                  CONS OF SPLASH
                    Be the first to leave a con

                    related Splash posts