diff options
author | John Molakvoæ <skjnldsv@protonmail.com> | 2022-12-28 15:29:54 +0100 |
---|---|---|
committer | John Molakvoæ <skjnldsv@protonmail.com> | 2023-01-04 16:46:14 +0100 |
commit | 5b9a8f0407a9e3fe7e00f0fc9284ea986905f1b5 (patch) | |
tree | 1363678dab6ed5e1554a7a74bc8a6a1a55bdf785 /cypress.config.ts | |
parent | 8f1bf13ae3046400ce6248fb13e5515e8e9ed5c4 (diff) | |
download | nextcloud-server-5b9a8f0407a9e3fe7e00f0fc9284ea986905f1b5.tar.gz nextcloud-server-5b9a8f0407a9e3fe7e00f0fc9284ea986905f1b5.zip |
Add component testing
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'cypress.config.ts')
-rw-r--r-- | cypress.config.ts | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/cypress.config.ts b/cypress.config.ts index b7c6934689a..02b0bbf2734 100644 --- a/cypress.config.ts +++ b/cypress.config.ts @@ -1,5 +1,12 @@ /* eslint-disable node/no-unpublished-import */ -import { applyChangesToNextcloud, configureNextcloud, preppingNextcloud, startNextcloud, stopNextcloud, waitOnNextcloud } from './cypress/dockerNode' + +import { + applyChangesToNextcloud, + configureNextcloud, + startNextcloud, + stopNextcloud, + waitOnNextcloud, +} from './cypress/dockerNode' import { defineConfig } from 'cypress' import browserify from '@cypress/browserify-preprocessor' @@ -29,6 +36,7 @@ export default defineConfig({ failSilently: false, type: 'actual', }, + screenshotsFolder: 'cypress/snapshots/actual', trashAssetsBeforeRuns: true, @@ -82,4 +90,24 @@ export default defineConfig({ }) }, }, + + component: { + devServer: { + framework: 'vue', + bundler: 'webpack', + webpackConfig: async () => { + process.env.npm_package_name = 'NcCypress' + process.env.npm_package_version = '1.0.0' + process.env.NODE_ENV = 'development' + + const config = require('@nextcloud/webpack-vue-config') + config.module.rules.push({ + test: /\.svg$/, + type: 'asset/source', + }) + + return config + }, + }, + }, }) |