const { defineConfig } = require("cypress");
const { cloudPlugin } = require("cypress-cloud/plugin");

module.exports = defineConfig({
  projectId: "RVEZS1",
  watchForFileChanges: false,
  video: false,
  viewportWidth: 1280,
  viewportHeight: 720,
  retries: {
    runMode: 2,
    openMode: 0,
  },
  reporter: "junit",
  reporterOptions: {
    mochaFile: "cypress/test-reports/cypress-results-[hash].xml",
    toConsole: true,
  },
  e2e: {
    // experimentalSessionAndOrigin: true,
    setupNodeEvents(on, config) {
      return cloudPlugin(on, config);
    },
    baseUrl: "http://localhost:8001",
  },
});
