mammadataei / cypress-vite

Run Cypress specs using Vite
MIT License
85 stars 10 forks source link

error #62

Closed f1am3d closed 1 year ago

f1am3d commented 1 year ago
The following error originated from your test code, not from Cypress.

  > Cannot read properties of undefined (reading 'on')

When Cypress detects uncaught errors originating from your test code it will automatically fail the current test.

Cypress could not associate this error to any specific test.

We dynamically generated a new test to display this failure.

cypress.config.ts

import { defineConfig } from 'cypress';
import vitePreprocessor from 'cypress-vite';

export default defineConfig({
  e2e: {
    baseUrl: 'http://localhost:5173',
    supportFile: false,

    setupNodeEvents(on) {
      on('file:preprocessor', vitePreprocessor());
    },
  },
});
mammadataei commented 1 year ago

@f1am3d What is rising the error? I think it's not from your config file since Cypress reports configuration errors differently. Can you provide more information like stack trace?

github-actions[bot] commented 1 year ago

This issue is automatically marked as stale because it has been open for 30 days with no activity. Remove the stale label or leave a comment, or it will be closed in 14 days.

github-actions[bot] commented 1 year ago

This issue was closed because it has been stalled for 14 days with no activity. Please feel free to open a new issue if you have any further questions.