/*
 * Copyright (C) 2022 StApps
 *  This program is free software: you can redistribute it and/or modify it
 *  under the terms of the GNU General Public License as published by the Free
 *  Software Foundation, version 3.
 *
 *  This program is distributed in the hope that it will be useful, but WITHOUT
 *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 *  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
 *  more details.
 *
 *  You should have received a copy of the GNU General Public License along with
 *  this program. If not, see <https://www.gnu.org/licenses/>.
 */

import {defineConfig} from 'cypress';

export default defineConfig({
  e2e: {
    reporter: 'junit',
    reporterOptions: {
      mochaFile: 'coverage/integration-report-junit-[hash].xml',
    },
    baseUrl: 'http://localhost:4200',
    injectDocumentDomain: true,
    supportFile: 'cypress/support/index.ts',
    videosFolder: 'cypress/videos',
    screenshotsFolder: 'cypress/screenshots',
    fixturesFolder: 'cypress/fixtures',
    defaultCommandTimeout: 20_000,
    specPattern: 'cypress/integration/**/*.spec.ts',
    blockHosts: ['mobile.server.uni-frankfurt.de'],
    /*setupNodeEvents(on, config) {
      on('task', {
        log(message) {
          console.log(message);
          return null;
        },
      });
    },*/
  },
});
