How to Test Drupal 11 Using Cypress and DDEV: Drupaladicto Explains
A new video published by Drupaladicto titled "Drupal 11 and Cypress, Testing with DDEV" explains how to set up and use Cypress for testing Drupal 11 projects with DDEV. Cypress is a free testing tool that lets users check how their website works right in the browser. Its simple interface makes it easier to create tests compared to other tools like Behat.
The video, which is in Spanish, provides clear instructions on how to prepare a local development environment using DDEV and install Drupal 11. After setting up Drupal, it explains how to add Cypress. The process requires Node.js, which is already included with DDEV. Viewers are guided on how to run the necessary commands to get Cypress up and running, as well as how to fix a common issue with DDEV's configuration that prevents the 'npx'
command from working.
To solve this problem, Drupaladicto recommends using a public code repository shared by Tyler36, which includes files to update the configuration and allow Cypress commands to work within DDEV. After everything is set up, users can access the Cypress interface, create test files, and run tests to check whether the website’s login system works correctly. The video walks viewers through an example of testing user login, showing how to update test files and re-run them to achieve a successful result. This guide is helpful for anyone looking to make website testing simpler and more efficient using Drupal, Cypress, and DDEV.
Disclosure: This content is produced with the assistance of AI.