Sorry Cypress is an open-source testing solution for Cypress.io that enables you to run your Cypress tests in a distributed and parallel manner. In this tutorial, we will guide you through the steps to install Sorry Cypress on Windows 10.
Before installing Sorry Cypress, you need to ensure that you have the following software installed on your Windows 10 computer:
To install Sorry Cypress, open a command prompt (or PowerShell) and execute the following command:
npm install -g sorry-cypress
This will install Sorry Cypress globally on your Windows 10 computer.
To verify that Sorry Cypress has been installed successfully, execute the following command:
sorry-cypress --version
This should return the current version of Sorry Cypress installed on your computer.
Sorry Cypress requires a MongoDB database to store the test data. You can either install MongoDB locally or use a cloud-based service like MongoDB Atlas.
To install MongoDB locally, follow these steps:
Download the MongoDB Community Server from the official website: https://www.mongodb.com/try/download/community
Run the installer and follow the instructions.
Once the installation is complete, create a new directory to store the MongoDB data.
Open a command prompt and navigate to the MongoDB bin directory. For example, if you installed MongoDB in C:\Program Files\MongoDB\Server\5.0\bin
, navigate to that directory.
Execute the following command to start the MongoDB process:
mongod.exe --dbpath C:\data\db
This will start the MongoDB server and create the db
directory in C:\data
.
If you prefer to use a cloud-based MongoDB instance, you can create a free account on MongoDB Atlas and follow the instructions to create a new cluster.
Once you have set up your MongoDB database, you need to configure Sorry Cypress to use it. To do so, create a new file named .env
in the root directory of your Cypress project and add the following variables:
MONGODB_URI=mongodb://localhost/sorry-cypress
MONGODB_DATABASE_NAME=sorry-cypress
Replace localhost
with your MongoDB server address if you are using a remote instance.
If you are using MongoDB Atlas, you can find your connection string in the Atlas dashboard under "Connect". Replace MONGODB_URI
with your connection string and set the MONGODB_DATABASE_NAME
to sorry-cypress
.
To start Sorry Cypress, navigate to the root directory of your Cypress project in a command prompt and execute the following command:
sorry-cypress start
This will start the Sorry Cypress server and create a dashboard that you can access in your browser.
Congratulations! You have successfully installed Sorry Cypress on your Windows 10 computer and configured it to use your MongoDB database. You can now run your Cypress tests in a distributed and parallel manner.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!