Skip to content

Latest commit

 

History

History
233 lines (184 loc) · 23.3 KB

javascript-test-automation.md

File metadata and controls

233 lines (184 loc) · 23.3 KB

JavaScript test automation

A comprehensive curated list of JavaScript test automation frameworks, tools, libraries and software to help software engineers easily bootstrap test automation on JavaScript. Sponsored by http://sdclabs.com

Have questions\issues\problems, join the chat at https://gitter.im/atinfo/awesome-test-automation

Table of content:

Also:


xUnit frameworks

Contribute to this section

TDD \ ATDD \ BDD

  • BDD/TDD
    • MochaJS - feature-rich JavaScript test framework running on node.js and the browser.
    • Jasmine - Behavior Driven Development testing framework for JavaScript. It does not rely on browsers, DOM, or any JavaScript framework. Thus it's suited for websites, Node.js projects, or anywhere that JavaScript can run.
    • Intern - is a complete test stack for JavaScript designed to help you write and run consistent, high-quality test cases for your JavaScript libraries and applications. It can be used to test any JavaScript code. Its functional testing capabilities can even be used to test non-JavaScript Web and mobile apps, if you really want.
    • Chai - Chai is a BDD / TDD assertion library for node and the browser that can be delightfully paired with any javascript testing framework
    • Chakram - Chakram is a REST API testing framework offering a BDD testing style and fully exploiting promises
  • BDD
    • CucumberJS - Cucumber is a tool for running automated tests written in plain language.Cucumber.js is the JavaScript implementation of Cucumber and runs on both Node.js and modern web browsers.
  • Runners
    • Karma - test runner for making TDD much easier by pre-build test environments.
    • Wallaby.js - Wallaby.js runs your JavaScript tests immediately as you type and displays execution results in your code editor. It also provides live test execution and code coverage reports.
    • Jest - Jest is used by Facebook to test all JavaScript code including React applications. One of Jest's philosophies is to provide an integrated "zero-configuration" experience. We observed that when engineers are provided with ready-to-use tools, they end up writing more tests, which in turn results in more stable and healthy code bases.
    • GlaceJS - quick-start functional testing framework based on mocha and extensible with plugins.
    • Apickli - REST API integration testing framework based on cucumber.js
    • Mocha Parallel Tests - mocha-parallel-tests is a test runner for tests written with mocha testing framework which allows you to run them in parallel.
    • Tupe - A generic unit-testing runner for front-end built on puppeteer.
    • AVA - 🚀 A test runner which takes advantage of NodeJS's asynchronous nature to parallelize IO, and run tests concurrently.
    • Gauge - A test runner for test specifications written in Markdown and implementations in JavaScript.

Mock frameworks

  • Sinon.JS - Standalone test spies, stubs and mocks for JavaScript. No dependencies, works with any unit testing framework.
  • JSMockito - JsMockito is a JavaScript stub/mock framework heavily inspired by java's Mockito.
  • apimocker - This is a node.js module to run a simple http server, which can serve up mock service responses. Responses can be JSON or XML to simulate REST or SOAP services.
  • rewire - Easy monkey-patching lib for node.js unit tests, which allows to inject mocks for other modules or globals like process, inspect private variables, override variables within the module.

Code analysis

  • ESLint - Pluggable JavaScript linting tool. Custom rules can be added to extend the existing functionality.
  • HintJS - Community driving js code analysis tool supported by twitter, facebook, wiki, jquery, mozilla, yahoo and others.
  • JsLint - JavaScript syntax checker and validator.

Web UI test automation

  • WebdriverJS - Nodejs webdriver language bindings official implementation from authors of selenium, includes only basic features and commands. Uses Control Flow to syncrhonize async actions.
  • WebdriverIO - Nodejs webdriver language bindings unofficial implementation. Has own handling of async actions using Fibers and rich set of features
  • Protractor - End-to-end test framework for Angular applications, comes with JasmineWD included, and built on top of WebdriverJS
  • CodeceptJS - Supercharged end 2 end testing for NodeJS
  • Nightwatch.js - Easy to use Node.js based End-to-End (E2E) testing solution for browser based apps and websites.
  • Dalek.js - Automated cross browser testing with JavaScript.
  • Nemo - Nemo provides a simple way to add selenium automation to your NodeJS web projects. With a powerful configuration ability provided by krakenjs/confit, and plugin architecture, Nemo is flexible enough to handle any browser/device automation need.
  • Frisby - Is a REST API testing framework built on node.js and Jasmine that makes testing API endpoints easy, fast, and fun.
  • TestCafe - Automated browser testing for the modern web development stack.
  • Nightmare - A high-level browser automation library.
  • Gemini - Is an open-source utility for automating visual regression testing of web pages. Gemini takes a screenshot of elements on a page and compares it with baseline images of these elements. If the images don't match, the differences are shown in a report. (Deperecated in favor of Hermione)
  • Hermione - Is the utility for integration testing of web pages using WebdriverIO and Mocha.
  • Gremlins.js - gremlins.js is a monkey testing library written in JavaScript, for Node.js and the browser. Use it to check the robustness of web applications by unleashing a horde of undisciplined gremlins.
  • 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. Built with <3 by the Chrome team.
  • Playwright - Playwright 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.
  • Chromeless - Works with AWS Lambda to deploy parallel testing in a serverless setup. Compared to incumbents, API is basic for now but it’s trending like a rocket now. Contributors and maintainers can shape it into a great tool.
  • Chrominator - Made by PhantomJS GhostDriver maintainer so the API is extensive. It covers many edge cases that users expect from mature headless browsers frameworks such as NightmareJS/Electron or CasperJS/PhantomJS.
  • Chromy - Possibly the earliest that shipped to market, releasing in early May a thoughtful set of high-level API that works with headless Chrome. Rapid improvements since then and actively explored by BackstopJS maintainer.
  • Navalia - Pretty refreshing approach by supporting the popular GraphQL language, which is normally meant for querying API endpoints. Looks to have a mature API set and most importantly it is well-documented.
  • Lambdium - Deployments on AWS Lambda using Selenium WebDriver. This is a very interesting proposition, because for the existing large Selenium code base in market, it has the potential for very easy migration to this tool.
  • GhostJS - Interesting project base on modern JavaScript that works on a multitude of browsers such as Chrome, Firefox, PhantomJS, plus expressive API. Released some time back, development seems to be picking up speed.
  • CasperJS - CasperJS is a navigation scripting & testing utility for PhantomJS and SlimerJS (still experimental). It eases the process of defining a full navigation scenario and provides useful high-level functions, methods & syntactic sugar for doing common tasks
  • Mailosaur - Node.js client for email testing/automation via Mailosaur.
  • Cypress.io - Fast, easy and reliable testing for anything that runs in a browser. Runs on Mac, Linux, Windows and any CI.
  • Differencify - A library for visual regression testing using Puppeteer.
  • Serenity/JS - Serenity/JS makes acceptance and regression testing of modern web apps faster, more collaborative and easier to scale.
  • Chimpy.js - An awesome developer-centric experience to writing tests with realtime feedback using Mocha, Jasmine or Cucumber.js
  • Sakuli - An awesome Node.js based End-to-End (E2E) testing solution which combines Selenium based web testing with full desktop automation. It's custom DSL allows to write complex scenarios which seamlessly switch between the browser and your desktop. It's built-in monitoring support allows to measure performance data from a user perspective.
  • Buster.js - A browser JavaScript/Node.js testing toolkit.
  • page-object - A Page Object pattern implementation library for JavaScript.
  • BackstopJS - BackstopJS automates visual regression testing of your responsive web UI by comparing DOM screenshots over time.
  • Taiko - A Node.js library to test and automate chromium browsers.
  • QA Wolf - A Node.js library to create browser tests 10x faster with Puppeteer and Jest.

API automation

  • SuperTest - Super-agent driven library for testing node.js HTTP servers using a fluent API.
  • Frisby - Frisby is a REST API testing framework built on Jest that makes testing API endpoints easy, fast, and fun.
  • Just-API - Declarative testing framework for REST, GraphQL APIs.
  • PactumJS - REST API Testing Tool for all levels in a Test Pyramid.
  • Got - Human-friendly and powerful HTTP request library for Node.js
  • Axios - Promise based HTTP client for the browser and node.js

Mobile test automation

  • WebdriverIO's Appium implementation - nodejs bindings implemeting Appium commands.
  • Macaca - Solution for Automation Test with Ease. Both Mobile, Desktop Platforms Supported, native, Hybrid, Mobile Web Multi-applications Supported, Command line tools & CI Solution provided.
  • Detox - Gray Box End-to-End Testing and Automation Framework for Mobile Apps
  • Cavy - Cavy is a cross-platform integration test framework for React Native, by Pixie Labs.

Windows UI test automation

  • RobotJS - The Node.js Desktop Automation Library
  • SikuliX - SikuliX automates anything you see on the screen of your desktop computer running Windows, Mac or some Linux/Unix. It uses image recognition powered by OpenCV to identify and control GUI components. This is handy in cases when there is no easy access to a GUI's internals or the source code of the application or web page you want to act on.
  • Sakuli - An awesome Node.js based End-to-End (E2E) testing solution which combines Selenium based web testing with full desktop automation. It's custom DSL allows to write complex scenarios which seamlessly switch between the browser and your desktop. It's built-in monitoring support allows to measure performance data from a user perspective.

Contribute to this section

Unix \ Linux UI test automation

  • SikuliX - SikuliX automates anything you see on the screen of your desktop computer running Windows, Mac or some Linux/Unix. It uses image recognition powered by OpenCV to identify and control GUI components. This is handy in cases when there is no easy access to a GUI's internals or the source code of the application or web page you want to act on.
  • Sakuli - An awesome Node.js based End-to-End (E2E) testing solution which combines Selenium based web testing with full desktop automation. It's custom DSL allows to write complex scenarios which seamlessly switch between the browser and your desktop. It's built-in monitoring support allows to measure performance data from a user perspective.

Contribute to this section

MacOS UI test automation

  • SikuliX - SikuliX automates anything you see on the screen of your desktop computer running Windows, Mac or some Linux/Unix. It uses image recognition powered by OpenCV to identify and control GUI components. This is handy in cases when there is no easy access to a GUI's internals or the source code of the application or web page you want to act on.
  • Sakuli - An awesome Node.js based End-to-End (E2E) testing solution which combines Selenium based web testing with full desktop automation. It's custom DSL allows to write complex scenarios which seamlessly switch between the browser and your desktop. It's built-in monitoring support allows to measure performance data from a user perspective.

Contribute to this section

Virtual environments

Contribute to this section

Performance & stress & load

  • k6 - Like unit testing, for performance. A modern load testing tool, using Go and JavaScript.
  • artillery - Artillery is a modern, powerful & easy-to-use load testing toolkit. Use it to build scalable applications that stay performant & resilient under high load.
  • predator - Distributed performance testing platform for APIs, using artillery as its load engine.

Security checking

Continuous Integration

  • Strider CD - Open Source Continuous Deployment / Continuous Integration platform written in NodeJS.
  • Gulp - Streaming building system/task runner in nodejs. Based on streaming data flow conception (https://github.com/substack/stream-handbook).
  • Grunt - Streaming building system/task runner in nodejs. Can't do anything without plugins, but there are many of them for all kinds of purposes.

Reporting

  • Testomat.io - test management and reporting system for javascript automated tests
  • ReportPortal.io - powerfull results management and analytics for test automation reports. Powered with Machine Learning. Real-time integration and reports, visualization of trends and statistics, custom dashboards and widgets, gives you real visibility into the state of test automation. Integral part of CI/CD with TA and Continous Testing. Server-client application, can be used for any type of automated tests, with huge list of available integrations. Free and OpenSourced, GitHub link.
  • Istanbul - JS coverage tool for unit tests, server side functional tests and browser tests.
  • Blanket - JavaScript code coverage library that works both in-browser and with nodejs.
  • Mochawesome - reporter for Mocha that generates a full fledged HTML/CSS report that helps visualize your test suites
  • Allure - a universal reporter for any testing framework. Supports Mocha and Jasmine (and Protractor)
  • cucumber-html-reporter - Provide Cucumber JSON report file created from your framework and this module will create pretty HTML reports. Choose your best suitable HTML theme and dashboard on your CI with available HTML reporter plugins.
  • Coveralls GitHub Action - A GitHub Action that will automatically report your latest test results to coveralls

Data-Driven Testing

  • test-each - Repeat tests using different inputs.

Documentation generation

  • JSdoc3 - An API documentation generator for JavaScript
  • jsdoc-to-markdown - Generates markdown API documentation from jsdoc annotated source code.
  • Docco - Docco is a quick-and-dirty documentation generator, written in Literate CoffeeScript
  • MrDoc - A personal source documenter
  • YUIDocs - YUI's JavaScript Documentation engine
  • ESDoc - Configurble documentation generator with good ES6/ES7 support

Contribute to this section

Editors, IDE, consoles

  • WebStorm - PhpStorm without php support. One of thee most powerfull JS/HTML IDE.
  • Brackets - Open source newly released IDE for JS/HTML from Adobe.
  • Komodo - Cross platform IDE for multiple languages, strongly supporting JS.
  • Cloud9 - Cloud based nodejs IDE supporting multiple features, eg. pair programming, preview in a new browser, built-in image editor, terminal and many others
  • Visual Studio Code - Cross platform editor from Microsoft, with integrated Node.js debugger and hooks for taskrunners such as Gulp
  • Atom - Full-featured, right out of the box text editor that's modern, approachable, yet hackable to the core from Github

Useful libs

  • faker - generate massive amounts of fake data in the browser and node.js
  • interfake - Fake APIs for prototypes & automated tests.
  • node-replay - When API testing slows you down: record and replay HTTP responses like a boss

Contribute to this section

Resources

Where to discover new libraries, information, tools, etc.

Websites

Articles

Other Awesome Test Automation Lists

Also we are supporting and looking for contribution for project:

Your contributions are always welcome!