GithubHelp home page GithubHelp logo

mssdef / cy-skeleton Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cjbramble/cy-skeleton

0.0 0.0 0.0 38 KB

Cypress template to make starting a new project faster.

Shell 2.74% JavaScript 97.26%

cy-skeleton's Introduction

Cypress Skeleton


Installation

Clone repository with SSH:

git clone <replace>

Switch to root of project:

cd <replace>

Install package:

npm install

Test install succeded:

./node_modules/.bin/cypress open


Configuration

In cypress.json the baseUrl is currently set to .

To override or use additional configurations create a separate cypress.env.json.

Example:

{
    "baseUrl": "<replace>"
}

Usage

We use custom Scripts in package.json to open Cypress, run all tests, and some other things from the command line.

"scripts": {
    "cy:open": "cypress open",
    "cy:run": "cypress run",
    "git:hook": "husky install",
    "format": "prettier --write ."
}

To open Cypress:

npm run cy:open

To run all tests:

npm run cy:run


Formatter

We're going to let robots do some formatting for us. Enable the git hook for Prettier by using a couple of scripts from package.json.

npm run git:hook

Now every time you make a commit the formatter will run. If you wish to run the formatter prior to commit (recommended) then just use the format script.

npm run format

Official Cypress Docs

https://docs.cypress.io/guides/overview/why-cypress

cy-skeleton's People

Contributors

cjbramble avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.