mirror of
https://github.com/cypress-io/cypress.git
synced 2026-01-10 00:30:37 -06:00
* begin removing migration code * remove migration query * add back actions * remove more migration references * more migration removals * remove call to migration * remove gqp-Migration file * updates to remove migration * update type * remove a lot more migration code - especially errors * Remove other errors/warnins for versions before 10.x * update error snapshots * fix some tests * index on remove-migration:49fa75ab78Merge branch 'remove-migration' of https://github.com/cypress-io/cypress into remove-migration * index on remove-migration:49fa75ab78Merge branch 'remove-migration' of https://github.com/cypress-io/cypress into remove-migration * index on remove-migration:49fa75ab78Merge branch 'remove-migration' of https://github.com/cypress-io/cypress into remove-migration * remove more system tests and references * fix call to refreshMetaState which was lost at initialization * rearrange some system tests to not be dependent on migration * update welcome version test * fix wording of messaging * skip irrelevant test * fix failing assertion * remove tests around cypress-plugin-retries * Remove test from config_spec * Remove screenshot from snapshot * fix tests + remove more migration projects * remove + update system tests * remove + update system tests * remove some invalid dev-server: start errors * remove references and tests around pluginsFile which was removed * remove some more invalid config examples * Add changelog entry * fix changelog link * fix unit test * index on remove-migration:490ddb134cMerge branch 'release/15.0.0' into remove-migration * index on remove-migration:490ddb134cMerge branch 'release/15.0.0' into remove-migration * index on remove-migration:490ddb134cMerge branch 'release/15.0.0' into remove-migration * run all binary/windows tests on this branch * Update packages/scaffold-config/test/unit/detect.spec.ts Co-authored-by: Bill Glesias <bglesias@gmail.com> * Update packages/scaffold-config/test/unit/detect.spec.ts Co-authored-by: Bill Glesias <bglesias@gmail.com> --------- Co-authored-by: cypress-bot[bot] <+cypress-bot[bot]@users.noreply.github.com> Co-authored-by: Bill Glesias <bglesias@gmail.com>
38 lines
876 B
JavaScript
38 lines
876 B
JavaScript
require('../cwd')
|
|
|
|
const EE = require('events')
|
|
const debug = require('debug')('cypress:ct:dev-server')
|
|
const plugins = require('../plugins')
|
|
|
|
const baseEmitter = new EE()
|
|
|
|
plugins.registerHandler((ipc) => {
|
|
baseEmitter.on('dev-server:specs:changed', (specsAndOptions) => {
|
|
ipc.send('dev-server:specs:changed', specsAndOptions)
|
|
})
|
|
|
|
ipc.on('dev-server:compile:success', ({ specFile } = {}) => {
|
|
baseEmitter.emit('dev-server:compile:success', { specFile })
|
|
})
|
|
})
|
|
|
|
// for simpler stubbing from unit tests
|
|
const API = {
|
|
emitter: baseEmitter,
|
|
|
|
start ({ specs, config }) {
|
|
return plugins.execute('dev-server:start', { specs, config })
|
|
},
|
|
|
|
updateSpecs (specs, options) {
|
|
baseEmitter.emit('dev-server:specs:changed', { specs, options })
|
|
},
|
|
|
|
close () {
|
|
debug('close dev-server')
|
|
baseEmitter.removeAllListeners()
|
|
},
|
|
}
|
|
|
|
module.exports = API
|