Testing Electron Applications - Tutorial

Applies to TestComplete 14.92, last modified on September 16, 2021

Electron applications are cross-platform applications created with web technologies (for instance, JavaScript, HTML, CSS). This tutorial explains how to test Electron applications with TestComplete. It assumes that you are familiar with general principles of automated testing and have minimal knowledge of the TestComplete IDE.

If you are new to TestComplete, we recommend that you first go through the Getting Started tutorial to get familiar with the tool.

In this tutorial, we are going to prepare an Electron application for testing, run it from TestComplete to get access to its internals, create and run a simple test and view the test results. The test will simulate a click in the application window and verify the text the application window shows.

Requirements

  • An active license for the TestComplete Web Module.

  • The following plugins must be enabled in TestComplete:

    • Web Testing

    • Chromium Embedded Framework Support

    These plugins are installed and enabled automatically as part of the TestComplete Web module. You can check if these plugins are active in File > Install Extensions (you can find them in the Web group).

  • The Quick Start application must be compiled as a binary executable file.

    To learn how to do it, see Prepare Your Electron Application for Testing. You can also find the instructions on how to distribute Electron applications as binary executables in the Electron documentation.

About Tested Application

In this tutorial, we will use a Quick Start sample application. It is the application used in the Quick Start tutorial in the Electron documentation. You can get the application’s source files there:

https://github.com/electron/electron-quick-start

For TestComplete to be able to test the application, the application must be compiled as a binary executable and launched from TestComplete. The instructions provided further describe how to do this.

Next

See Also

Testing Electron Applications - Tutorial
About Testing Electron Applications
Testing Web Applications - Tutorial

Highlight search results