Skip to content

Open-source live-chat, email support, omni-channel desk. An alternative to Intercom, Zendesk, Salesforce Service Cloud etc. πŸ”₯πŸ’¬

1.2 KB
Raw Blame

Chatwoot E2E Testing

End-to-end testing framework for Chatwoot using Component Object Model pattern.

Setup

# Install dependencies
pnpm install

# Install Playwright browsers
npx playwright install

# Configure environment
cp .env.example .env

Edit .env with your Chatwoot instance URL and credentials.

Usage

# Run all tests
pnpm run playwright:run

# Run tests in UI mode
pnpm run playwright:open

# Lint tests and page objects
pnpm run lint

# Generate test code
pnpm run playwright:codegen

Project Structure

tests/playwright/
β”œβ”€β”€ components/
β”‚   β”œβ”€β”€ api/              # API interaction components
β”‚   └── ui/               # UI page objects
β”œβ”€β”€ tests/
β”‚   └── e2e/
β”‚       β”œβ”€β”€ api/          # Pure API tests
β”‚       └── ui/           # UI tests
β”œβ”€β”€ utils/                # Shared utilities and helpers
β”œβ”€β”€ response-schemas/     # API response schemas for validation
β”œβ”€β”€ fixtures/             # Test fixtures
└── helpers/              # Helper functions

Documentation

See DOCS.md for complete testing guide including patterns, conventions, and troubleshooting.

Configuration

See .env.example for the full list of variables.