Skip to content

Frontend e2e tests failing due to missing CypressFields export #178

@osullivandonal

Description

@osullivandonal

Bug Report

Using 535280b (latest from main).

Symptom

Running make run-tests locally the frontend e2e tests fail with TypeError: Cannot read properties of undefined (reading 'HomePage') and TypeError: Cannot read properties of undefined (reading 'CurrencySwitcher').

What is the expected behavior?
The frontend e2e tests should pass when running make run-tests.

What is the actual behavior?
Tests fail with undefined property errors:

TypeError: Cannot read properties of undefined (reading 'HomePage')
      at Context.eval (webpack://frontend/./cypress/e2e/Home.cy.ts:14:22)

TypeError: Cannot read properties of undefined (reading 'CurrencySwitcher')  
      at Context.eval (webpack://frontend/./cypress/e2e/Home.cy.ts:21:22)

Reproduce

  1. Clone the repository
  2. Run make run-tests
  3. Observe that Home.cy.ts tests fail with undefined property errors

The issue is in src/frontend/cypress/e2e/Home.cy.ts - it imports CypressFields from ../../utils/Cypress but the utils/Cypress.ts file doesn't export CypressFields, causing it to be undefined at runtime.

Additional Context

  • This affects the Docker-based Cypress test environment
  • The fix is to ensure CypressFields is properly exported from the utils file
  • Other test files may be affected if they rely on the same import pattern
  • I can provide a fix if maintainers are interested

Environment: Docker-based Cypress tests, Node.js frontend build

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions