Skip to content

Electron app test automation using Playwright, TypeScript, NodeJS, and a sprinkle of RobotJS

Notifications You must be signed in to change notification settings

steven-the-qa/electron-automation-template

Repository files navigation

Use Playwright to test the Notion native app

Introduction

Automate tests for your Electron apps using Playwright & TypeScript!

GitHub Repo

https://github.com/steven-the-qa/electron-automation-template

Tech Stack

  • Playwright (ElectronJS app testing support)
  • TypeScript (type safety)
  • NodeJS (writing to the file system)
  • RobotJS (Playwright doesn't do keyboard navigation well within a select menu)

Getting Started

  1. Clone the repository
  2. IF ON WINDOWS (maybe just Windows 10, idk), install an extra dependency to support RobotJS keyboard commands BEFORE installing all dependencies (otherwise, things get weird):
npm install -g node-gyp
  1. Install the Visual Studio Tools with the "Desktop Development with C++" workload to support node-gyp
  2. To install all dependencies minus unnecessary Playwright browsers (because Electron), run:
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 npm ci
  1. To run tests, run npm test from the root directory

About

Electron app test automation using Playwright, TypeScript, NodeJS, and a sprinkle of RobotJS

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published