Skip to main content

Introduction

Chathai is a powerful tool that helps you generate Cypress test scripts from Excel test cases. It simplifies the process of converting your test cases into executable test scripts, saving you time and reducing the chance of errors.

Quick Start

npm install chathai --save-dev
npx chathai generate

Installation

You can install Chathai in two ways:

  1. As a dev dependency in your project:
npm install chathai --save-dev
  1. Globally on your system:
npm install -g chathai

Basic Usage

The simplest way to use Chathai is to run:

npx chathai generate

This will:

  1. Create a default Excel template if one doesn't exist
  2. Generate Cypress test scripts in the cypress/e2e directory
  3. Use the default template structure

Excel Template Structure

The default template includes the following columns:

  • Test Case ID
  • Test Case Name
  • Description
  • Steps
  • Expected Result
  • Actual Result
  • Status

Advanced Usage

Using Custom Excel File

npx chathai generate path/to/your/excel.xlsx

Specifying Custom Output Directory

npx chathai generate path/to/your/excel.xlsx custom/output/directory

Example Project

  1. Create a new project:
mkdir my-test-project
cd my-test-project
npm init -y
npm install chathai --save-dev
  1. Generate test scripts:
npx chathai generate
  1. The generated test scripts will be available in the cypress/e2e directory.

Contributing

We welcome contributions! Please feel free to submit a Pull Request.

Support

If you encounter any issues or have questions, please open an issue on GitHub.