Skip to Content
Documentation
QA
CypressUnderstanding Test Results

✅❌ Understanding Test Results

When running Cypress tests, you will see different statuses based on the execution results. Here’s how to interpret them:

📌 Test Structure Overview

Each test follows a structured format:

  • Test File → The script being executed (e.g., AIWebsite.test.js)

  • Test Suite Name → Groups related tests together (e.g., Dynamic Website Functionality Checks)

    • In VS Studio Code: cypress
  • Testing Website: → The specific website under evaluation

    • In VS Studio Code: cypress
  • Test Cases → Individual checks performed on the website (e.g., Copyright year should display the current year)

    • In VS Studio Code: cypress cypress
  • Status Indicators:

    • Success → Test passed (expected result met)
    • Failure → Test did not meet the expected result

🟢 Example: Test Run

cypress

📌 What this means:

  • The test suite Dynamic Website Functionality Checks executed successfully
  • The website Radiance was tested
  • The copyright year was verified correctly (✅ passed)
  • However, the robots.txt file was not found or had incorrect settings (❌ failed)

🔄 Before Each (Setup Phase)

Each test case has a setup phase before execution. This ensures:

  • The test starts with a clean slate
  • The browser navigates to the correct website
  • Necessary conditions are met (e.g., logging in, loading test data) cypress

🏗️ Test Body (Execution Phase)

This contains the actual commands Cypress runs, such as:

  • Checking page elements (e.g., cy.get(“footer”).should(“contain”, “2024”))
  • Navigating pages (e.g., cy.visit(“example.com”)) cypress

⚠️ VERY IMPORTANT NOTE – REPORTING UNEXPECTED ERRORS

If you encounter any errors or unexpected results, such as Cypress failing to find an element or timing out: cypress

  1. 🚫 List down the error message
  2. 📍 Include the website being tested where the error occurred
  3. 📋 Send the details so the repository can be updated and investigated

By reporting these issues, I can update the repo and check for possible fixes. 🚀

Last updated on