←Back to Dictionary

Cypress

1 / 3
🎥 Cypress — Introduction

In this course, Cypress means a tall, slender, dark-green conifer of the genus Cupressus, native to warm. A related lesson is the tree course. One citation is the Cambridge English entry, and a second is the Cambridge entry for tree. Encyclopaedic background is in Cypress.

Narrator · Google UK English Female · Documentary
Ready
🎤 Cypress — Daily Use
Speaker A & Speaker B · British Conversation
Ready
💻 Cypress — Prompt Engineering
Instructor & Developer · Tech Dialogue
Ready

Transcript: “Cypress” vocabulary micro-course

Read along with the three podcasts, or open the full dictionary entry for Cypress for the definition, Arabic meaning, synonyms and example sentences.

Podcast 1 — Introduction & meaning

Narrator: The word cypress. A noun. Pronounced: SY-press. In IPA: slash ˈsaɪprəs slash. Note: it is not sy-PRESS — the stress falls on the first syllable.

Narrator: Cypress has two distinct modern meanings. The first and older is a tall, slender, dark-green conifer of the genus Cupressus, native to warm climates across the Mediterranean, the Middle East, and western Asia. The second is a JavaScript-based end-to-end testing framework for web applications, now one of the most widely used tools in modern front-end development. This course covers both meanings and their very different contexts.

Narrator: The botanical name comes from the Latin cupressus, borrowed from Greek kyparissos — a word of uncertain pre-Greek origin. The cypress tree appears throughout ancient Mediterranean culture as a symbol of mourning and immortality, associated with death and the afterlife in Greek, Roman, Persian, and later Islamic traditions. Its dark, narrow form planted beside cemeteries is still a visual shorthand for bereavement across Southern Europe and the Middle East.

Narrator: In classical mythology, Kyparissos was a youth beloved by Apollo who, after accidentally killing a sacred deer, asked to mourn forever and was transformed into a cypress tree. The association with grief and permanent loss is therefore embedded in the word at a mythological level. When Italian Renaissance painters filled landscapes with cypress trees, viewers understood the visual language immediately.

Narrator: Cypress wood itself is highly durable, aromatic, and resistant to rot. It was used to build the doors of Saint Peter's Basilica in Rome, which lasted over a thousand years. Ancient Egyptians used it for coffins, a choice entirely consistent with the tree's funerary symbolism.

Narrator: In the modern software world, Cypress — with a capital C — is an open-source front-end testing tool first released in 2017. Unlike older testing frameworks, Cypress runs tests directly inside the browser, giving developers the ability to interact with live applications in real time. It became popular quickly because of its readable syntax, automatic waiting, and integrated debugging features.

Narrator: The two meanings of cypress share almost no vocabulary overlap in professional usage. In horticulture, architecture, and art history, cypress refers to the tree. In software development, Cypress refers to the testing tool. Context makes the reading unambiguous in practice.

Narrator: A word that began as a tree of mourning in ancient Greece and became, in the twenty-first century, one of the essential tools for testing whether websites behave as they should.

Read podcasts 2 and 3

Podcast 2 — In conversation

Speaker A: I had a slight embarrassment last week. A developer sent me a message asking if I had used Cypress on the project, and I replied enthusiastically about how much I love the trees in Tuscany. He was baffled for about thirty seconds.

Speaker B: That is a perfect illustration of how two completely unrelated meanings share a word without any visible connection between them. In botany, a cypress is the dark, columnar Mediterranean tree. In software development, Cypress is a testing framework for web applications. The two share a name and absolutely nothing else.

Speaker A: I have since spent some time with the software. What is Cypress actually for?

Speaker B: Cypress is an end-to-end testing framework — it automates a real browser and interacts with your web application the way a user would. It fills in forms, clicks buttons, navigates between pages, and checks that the results match what you expected. It catches bugs that unit tests miss, because unit tests check individual functions in isolation while Cypress checks how the whole application behaves together.

Speaker A: How does it compare to Selenium, which is the testing framework I had heard of before?

Speaker B: Selenium is older and runs tests outside the browser, communicating with it via a driver. Cypress runs directly inside the browser process, which makes it faster and more reliable — you get fewer flaky tests caused by timing issues. Cypress also has a built-in interactive test runner where you can watch each test step execute in real time, which Selenium does not provide out of the box. For modern React, Vue, or Angular applications, Cypress has largely become the default choice.

Speaker A: And the tree? I want to make sure I know how to use it correctly outside a software context.

Speaker B: In a non-technical context, cypress always means the tree. A row of cypresses lines the road to the villa. The churchyard was planted with tall, dark cypresses. You would also see it in art history — the cypresses in Van Gogh's paintings are famously expressive, rendered with that swirling, flame-like energy. And in garden design, Italian cypress specifically refers to the pencil-thin Tuscan variety used as a formal vertical accent.

Speaker A: So the only situation where I need to think carefully about which meaning applies is when talking to developers.

Speaker B: Exactly. In any software or web development conversation, Cypress means the testing tool. In every other context, cypress means the tree. The capital letter on the software name is technically the signal, but in speech you rely entirely on context.

Podcast 3 — Prompt engineering

Speaker B: Cypress in AI prompts almost always means the testing framework in a development context, and it is one of the most productive words for generating production-quality test suites, CI configurations, and test strategy documents. Let us go through the most useful patterns.

Speaker A: I have started writing Cypress tests but I often feel like I am writing them from scratch every time rather than building on a reusable approach.

Speaker B: That is exactly what the right prompts solve. Start with a basic end-to-end test suite:

Speaker B: PROMPT: Write a Cypress end-to-end test suite for a user authentication flow. Cover: loading the login page and verifying the form renders correctly, submitting with valid credentials and asserting redirect to the dashboard, submitting with invalid credentials and asserting the error message displays, testing the remember me checkbox persists the session, and testing the logout button clears the session and redirects to login. Use cy.intercept to mock the authentication API responses.

Speaker A: Using cy.intercept to mock API responses is the technique that makes authentication tests reliable — you are not depending on a real auth server being available during the test run.

Speaker B: A Cypress test for a complex form with validation:

Speaker B: PROMPT: Write a Cypress test file for a multi-step registration form with three steps: personal details, address, and payment. Each step has client-side validation. Test that required field errors display correctly when the user clicks Next without filling required fields, that the Back button preserves entered values, that the address step auto-completes via a mocked postcode lookup API using cy.intercept, and that the payment step submits to a mocked endpoint and shows a success confirmation screen.

Speaker A: Testing that Back preserves entered values is the user experience detail that is easy to break and almost never covered by unit tests.

Speaker B: A Cypress configuration for a CI pipeline:

Speaker B: PROMPT: Write a GitHub Actions workflow that runs Cypress end-to-end tests on every pull request. Start the Node.js development server, wait for it to be ready on port 3000 using cypress-wait-on, then run the full Cypress test suite headlessly with cypress run. Upload the Cypress screenshots and videos from cypress/screenshots and cypress/videos as artefacts on test failure. Fail the workflow if any test fails. Use Node.js 20 and cache node_modules between runs.

Speaker A: Caching node_modules and uploading failure artefacts are the two CI details that save significant time across a busy week of pull requests.

Speaker B: A Cypress custom command library:

Speaker B: PROMPT: Create a Cypress custom commands file at cypress/support/commands.js with these reusable commands: cy.login accepts email and password and performs a full programmatic login via API to avoid repeating UI login steps in every test, cy.seedDatabase calls a test setup endpoint to reset the database to a known state before each test run, and cy.assertToast accepts a message string and asserts the toast notification with that text is visible. Document each command with a JSDoc comment explaining its parameters and expected behaviour.

Speaker A: The programmatic login command that bypasses the UI is the performance optimisation every Cypress project needs — repeating a full login flow through the UI before every test wastes minutes across a full test suite.

Speaker B: A Cypress dashboard and reporting configuration:

Speaker B: PROMPT: Configure Cypress to record test results to the Cypress Dashboard for a team project. Add the projectId and record flag to cypress.config.js. Write a Node.js script that reads the Cypress last run JSON results file after each CI run, calculates the pass rate and average test duration, and posts a Slack notification via webhook with a summary showing total tests, passed, failed, skipped, and the five slowest individual tests by duration.

Speaker A: The five slowest tests in the Slack notification is the visibility that drives test performance improvement — you only fix slow tests when someone has to look at them after every run.

Speaker B: A Cypress accessibility test integration:

Speaker B: PROMPT: Integrate cypress-axe into an existing Cypress test suite to run automated accessibility checks. Add a beforeEach hook that injects axe-core on every page visit. Write a dedicated accessibility spec that visits each main application route — home, login, dashboard, settings, and profile — and calls cy.checkA11y with a violation threshold of zero for critical and serious issues. Log a formatted summary of all violations to the console and save the full axe results as a JSON artefact using cy.writeFile.

Speaker A: Setting the threshold to zero for critical and serious violations rather than all violations is the pragmatic accessibility standard — it catches the issues that genuinely harm users while allowing the team to address lower-priority cosmetic issues on a separate track.

Speaker B: A full Cypress project scaffold:

Speaker B: PROMPT: Scaffold a complete Cypress project structure for a React SaaS application. Include cypress.config.js with baseUrl, viewport settings of 1280 by 720, default command timeout of 8000 milliseconds, and video recording enabled. Create the directory structure with cypress/e2e for test files, cypress/fixtures for test data JSON files, cypress/support for commands.js and e2e.js. Write a sample spec covering the main dashboard render, a data table with sorting and pagination, and a modal dialog open and close interaction. Add a package.json script for local and CI execution.

Speaker A: Having a complete scaffold prompt means I can set up a properly structured Cypress project for a new application in minutes rather than piecing together the configuration from documentation each time.

Speaker B: Cypress in a prompt is the signal that you want production-quality, real-browser automated testing — not unit test stubs or mock demonstrations. When you include it, the AI generates code that runs against a real application, handles asynchrony correctly, uses cy.intercept for API control, and fits into a CI pipeline. That is the full testing workflow that teams actually need.