File tree Expand file tree Collapse file tree 3 files changed +1427
-2
lines changed
vite-react-microfrontends Expand file tree Collapse file tree 3 files changed +1427
-2
lines changed Original file line number Diff line number Diff line change 1+ const concurrently = require ( 'concurrently' ) ;
2+ const commands = {
3+ startHost : 'yarn serve:host' ,
4+ startRemote : 'yarn serve:remote' ,
5+ startE2e : 'yarn e2e:test'
6+ } ;
7+
8+ const { result} = concurrently ( [
9+ commands . startHost ,
10+ commands . startRemote ,
11+ commands . startE2e
12+ ] , {
13+ killOthers : [ 'failure' , 'success' ] ,
14+ } ) ;
15+
16+ function handleClose ( exitInfo ) {
17+ const testResult = exitInfo . find ( info => info . command . command === commands . startE2e ) ;
18+ process . exit ( testResult . exitCode ) ;
19+ }
20+
21+ result . then ( handleClose , handleClose ) ;
Original file line number Diff line number Diff line change 1717 "build:remote" : " npm --prefix ./remote run build" ,
1818 "preview:host" : " npm --prefix ./host run preview" ,
1919 "preview:remote" : " npm --prefix ./remote run preview" ,
20- "e2e:ci" : " yarn preview:remote & yarn preview:host & wait-on http-get://localhost:4174/ && npx cypress run --config-file ../cypress/config/cypress.config.ts --config '{\" supportFile\" : \" ../cypress/support/e2e.ts\" }' --spec \" ./e2e/tests/runAll*.cy.ts\" --browser=chrome"
20+ "e2e:test" : " npx cypress run --config-file ../cypress/config/cypress.config.ts --config '{\" supportFile\" : \" ../cypress/support/e2e.ts\" }' --spec \" ./e2e/tests/runAll*.cy.ts\" --browser=chrome" ,
21+ "e2e:ci" : " node e2e.ci.js"
2122 },
2223 "author" : {
2324 "name" : " Giorgio Boa" ,
2627 },
2728 "license" : " ISC" ,
2829 "devDependencies" : {
30+ "concurrently" : " 7.3.0" ,
2931 "wait-on" : " 7.0.1"
3032 }
3133}
You can’t perform that action at this time.
0 commit comments