cypress-crud-api-test
tour-of-heroes-react-cypress-ts
cypress-crud-api-test | tour-of-heroes-react-cypress-ts | |
---|---|---|
3 | 6 | |
8 | 22 | |
- | - | |
9.6 | 9.4 | |
4 days ago | 3 days ago | |
TypeScript | TypeScript | |
- | - |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
cypress-crud-api-test
-
Improve Cypress e2e test latency by a factor of 20!!
Any blog post is lackluster without working code, so here is a PR from scratch adding esbuild to a repository with Cypress. You can find the final code on the main branch of the repository we will use in this example. Other examples can be found at tour-of-heroes-react-cypress-ts as well as a VueJS app. The framework and the bundler the framework uses are irrelevant, any repo can take advantage of cypress-esbuild-preprocessor for e2e tests.
-
Effective Test Strategies for Deployed NodeJS Services using LaunchDarkly Feature Flags and Cypress. Part2: testing
This is part two of a multi-part series. In the previous post we setup the flags, now we will test them. Before diving into testing feature flags, we will setup Cypress and transfer over the final CRUD e2e spec from the repo cypress-crud-api-test. That repo was featured in the blog post CRUD API testing a deployed service with Cypress. Note that the said repo and this service used to be separated - that is a known anti-pattern - and now we are combining the two in a whole. The change will provide us with the ability to use the LaunchDarkly (LD) client instance to make flag value assertions. We would not have that capability if the test code was in a separate repo than the source code, unless the common code was moved to a package & was imported to the two repos. In the real world if we had to apply that as a solution, we would want to have valuable trade-offs.
-
CRUD API testing a deployed service with Cypress using cy-api, spok, cypress-data-session & cypress-each
The code for this entire guide is available at GitHub. For learning purposes, you can check out the branch base to start from scratch and follow the guide. main has the final version of the repo. The code samples are setup to copy paste into the repo and work at every step.
tour-of-heroes-react-cypress-ts
-
Cypress Component Testing vs React Test Library - the complete comparison
ToH is the final app built in the book CCTDD: Cypress Component Test Driven Design. It has a few dozen Cypress component tests and their RTL mirrors. We will cover a few examples to showcase the main differences.
-
CI CD strategies for UI apps and deployed services
We'll start by examining a Tour of Heroes repo, featured in the book CCTDD: Cypress Component Test Driven Design. This repository demonstrates various test checks, including lint (ESLint), type checks (TS), unit tests (Jest), and Cypress component tests & end-to-end tests. The tests are parallelized to reduce feedback time to approximately five minutes, which is an optimal duration to promote a continuous feedback loop for this size of repo.
-
Improve Cypress e2e test latency by a factor of 20!!
Any blog post is lackluster without working code, so here is a PR from scratch adding esbuild to a repository with Cypress. You can find the final code on the main branch of the repository we will use in this example. Other examples can be found at tour-of-heroes-react-cypress-ts as well as a VueJS app. The framework and the bundler the framework uses are irrelevant, any repo can take advantage of cypress-esbuild-preprocessor for e2e tests.
-
Ramda & Functional Programming with React & TypeScript
This is a new section in my book, chapter 20 of CCTDD: Cypress Component Test Driven Design. It is being shared here to reach a wider audiance. All the content is paired with the application Tour of Heroes in React Cypress TS. The PR for the functional refactor can be found in here. While all the code is copy pastable, you can find working prototypes here and here.
-
Triple combined coverage with Typescript
In the previous post we covered triple combined coverage in a React app written in JS . Alas, Typescript can be tricky with combined code coverage. We continue the series with a Typescript example using the React TS app featured in the book CCTDD: Cypress Component Test Driven Design. The application built in the book is in TS, includes Cypress e2e, CT tests, as well as React Testing Library mirrors of them. The repo tour-of-heroes-react-cypress-ts has the final version of the repo with triple combined coverage setup. The state of the repo prior to code coverage is in the branch before-code-coverage and there is a sample PR for reproducing this guide.
What are some alternatives?
pizza-api
react - A declarative, efficient, and flexible JavaScript library for building user interfaces.
cypress-data-session - Cypress command for flexible test data setup
cypress-esbuild-preprocessor - Bundle Cypress specs using esbuild
cypress-ld-control - Set LaunchDarkly feature flags from Cypress tests
appsyncmasterclass-backend - Backend for a Twitter Clone built with Serverless Framework, JS, AWS AppSyc, Lambda, DynamoDB & Cognito.
react-hooks-in-action-with-cypress - React Hooks in Action Book, with Cypress e2e & component tests
books - Self-learning exercises from my favorite JS related books
spok - Checks a given object against a given specification to keep you from writing boilerplate tests.
cy-spok - Playing with spok inside Cypress
github-action - GitHub Action for running Cypress end-to-end & component tests