/testcafe-js

TestCafe JavaScript Framework

Primary LanguageJavaScript

About The Project

Software The project implements TestCafe (JavaScript-based testing tool/framework), in order to conduct end-to-end (E2E) testing on any client owned test environment.

Using this project, the QA team will be responsible for:

  • Verifying the working order of a software product in a start-to-finish process
  • Testing from the end user’s experience by simulating real user scenarios
  • Validating the system under test and its components for integration and data integrity
  • Reporting the results considered to be bugs and fixes

Additionally, this project will allow the team to test the web application on different browsers.

Built With

The following frameworks/languages/libraries are used to bootstrap this project.

TestCafe JavaScript HTML

Getting Started

Here gives you instructions on setting up your project locally.

  1. Clone the repository:

    git clone https://github.com/Amanimal/testcafe-js.git
    
  2. Install dependencies, using terminal:

    cd ./testcafe-js npm install
    
  3. Verify TestCafe is installed, using terminal:

    testcafe -v
    
  4. Ensure the project contains the following directories/files:

    a. \reports directory, contains generated reports are stored for all tests ran on different browsers
    b. \screenshots directory, contains screenshots of each failed test case
    c. \videos directory, contains videos of each test run

NOTE: TestCafe run will automatically create \reports, \screenshots and \videos directories

Usage

Use the information below to learn how to run this project.

Running Tests

  1. Run a test file:
    testcafe chrome mytestfile.js
    
  2. Run a test file in live mode:
    testcafe chrome mytestfile.js --live
    

NOTE: While running in live mode, test scripts can be modified using a code editor or an IDE, simultaneously.

  1. Run all tests, inside tests directory:
    testcafe chrome tests/*.js
    

NOTE: Browsers: chrome, edge, firefox, opera and safari can be used as an argument to run tests on.

  1. Run all tests using configurarion file:
    testcafe --config-file testcafe.config.js
    

By default, this will run all tests inside tests directory, on all browsers specified.

Happy Testing!