mirror of
https://github.com/mempool/mempool.git
synced 2025-02-22 06:21:46 +01:00
Remove the deprecated plugins file
This commit is contained in:
parent
1ac8e5004f
commit
545b5be7d4
2 changed files with 12 additions and 19 deletions
|
@ -1,4 +1,4 @@
|
|||
import { defineConfig } from 'cypress'
|
||||
import { defineConfig } from 'cypress';
|
||||
|
||||
export default defineConfig({
|
||||
projectId: 'ry4br7',
|
||||
|
@ -12,12 +12,18 @@ export default defineConfig({
|
|||
},
|
||||
chromeWebSecurity: false,
|
||||
e2e: {
|
||||
// We've imported your old cypress plugins here.
|
||||
// You may want to clean this up later by importing these.
|
||||
setupNodeEvents(on, config) {
|
||||
return require('./cypress/plugins/index.js')(on, config)
|
||||
setupNodeEvents(on: any, config: any) {
|
||||
const fs = require('fs');
|
||||
const CONFIG_FILE = 'mempool-frontend-config.json';
|
||||
if (fs.existsSync(CONFIG_FILE)) {
|
||||
let contents = JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
||||
config.env.BASE_MODULE = contents.BASE_MODULE ? contents.BASE_MODULE : 'mempool';
|
||||
} else {
|
||||
config.env.BASE_MODULE = 'mempool';
|
||||
}
|
||||
return config;
|
||||
},
|
||||
baseUrl: 'http://localhost:4200',
|
||||
specPattern: 'cypress/e2e/**/*.{js,jsx,ts,tsx}',
|
||||
},
|
||||
})
|
||||
});
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
const fs = require('fs');
|
||||
|
||||
const CONFIG_FILE = 'mempool-frontend-config.json';
|
||||
|
||||
module.exports = (on, config) => {
|
||||
if (fs.existsSync(CONFIG_FILE)) {
|
||||
let contents = JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
||||
config.env.BASE_MODULE = contents.BASE_MODULE ? contents.BASE_MODULE : 'mempool';
|
||||
} else {
|
||||
config.env.BASE_MODULE = 'mempool';
|
||||
}
|
||||
return config;
|
||||
}
|
Loading…
Add table
Reference in a new issue