pages235/cypress/plugins/index.js
Vitaly 9227ccc7d6 first real cypress test, try on ci
remove refs to unimplemented components for now
2023-08-17 05:35:29 +03:00

26 lines
706 B
JavaScript

//@ts-check
const { cypressEsbuildPreprocessor } = require('cypress-esbuild-preprocessor')
const { initPlugin } = require('cypress-plugin-snapshots/plugin')
const polyfill = require('esbuild-plugin-polyfill-node')
module.exports = (on, config) => {
initPlugin(on, config)
on('file:preprocessor', cypressEsbuildPreprocessor({
esbuildOptions: {
plugins: [
polyfill.polyfillNode({
polyfills: {
crypto: true,
},
})
],
},
}))
on('task', {
log (message) {
console.log(message)
return null
},
})
return config
}