Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sonngdev/cypress-starter

Basic starting template for Cypress, with TypeScript and Cypress Testing Library.
https://github.com/sonngdev/cypress-starter

Last synced: about 5 hours ago
JSON representation

Basic starting template for Cypress, with TypeScript and Cypress Testing Library.

Awesome Lists containing this project

README

        

# Cypress Starter Template

This is a template to quickly get you started on E2E testing with [Cypress](https://www.cypress.io/). It comes with [TypeScript](https://www.typescriptlang.org/) out of the box, and includes [Cypress Testing Library](https://testing-library.com/docs/cypress-testing-library/intro/) that help you write good-practice queries. All typing are pre-configured for you, so you get great code-suggestion support from modern IDEs (like Visual Studio Code).

## Features

- ⭐️ Cypress 10
- ⭐️ TypeScript 4.7.3
- ⭐️ Cypress Testing Library 8.0.3

## Installation

Clone this repo

```bash
git clone [email protected]:thanhsonng/cypress-starter.git
```

Install dependencies

```bash
npm i
```

Run Cypress

```bash
npm run test:e2e
```

🎉 Done. You can now start writing your first test suite.

⚠️ **Note**: By default, it uses Chrome as the default browser, and it directly shows all the tests in E2E mode. If you want other options, use Cypress UI by adding this script to `package.json` then run it.

```json
"test:open": "cypress open"
```

```bash
npm run test:open
```