Skip to content

Running Cypress Tests

Alan Bergsneider edited this page Dec 4, 2022 · 1 revision

Recently, Cypress was added to HearSay's front-end client, along with some tests. Here's how to run them locally!

Prerequisites

  • You've followed the steps outlined in the project README to clone the project and set up all necessary environment variables to get started.

Steps

  1. Open HearSay/hearsay-client in your terminal, and in your workspace.
  2. Run the following commands in this order: npm install && npm run build && npm start
  3. Open a new terminal instance in the same directory
  4. Run npm run cypress
  5. Begin tinkering!

Notes

  • These tests run automatically as a part of a continuous integration github action made whenever someone makes a pull request or pushes.
  • Changes cannot be approved if the workflow fails.
  • In order to make this work, the back-end of HearSay had to be adjusted to support exclusively non-local models so that it could be deployed to the cloud
  • More updates will be made to make HearSay's back-end resistant to a lot of issues that could arise now with increased usage.

Video

This video explains the Cypress tests a bit as well as the GitHub action that runs them anytime a pull request or push is made now