File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -37,9 +37,6 @@ describe('preact', () => {
3737
3838 it ( 'should use a custom `.env` with prefixed environment variables' , async ( ) => {
3939 let app = await create ( 'default' ) ;
40- server = await watch ( app , 8085 ) ;
41-
42- let page = await loadPage ( chrome , 'http://127.0.0.1:8085/' ) ;
4340
4441 let header = resolve ( app , './src/components/header/index.js' ) ;
4542 let original = await readFile ( header , 'utf8' ) ;
@@ -48,6 +45,14 @@ describe('preact', () => {
4845 '<h1>{process.env.PREACT_APP_MY_VARIABLE}</h1>'
4946 ) ;
5047 await writeFile ( header , update ) ;
48+ await writeFile (
49+ resolve ( app , '.env' ) ,
50+ 'PREACT_APP_MY_VARIABLE="Hello World!"'
51+ ) ;
52+
53+ server = await watch ( app , 8085 ) ;
54+
55+ let page = await loadPage ( chrome , 'http://127.0.0.1:8085/' ) ;
5156
5257 // "Hello World!" should replace 'process.env.PREACT_APP_MY_VARIABLE'
5358 await waitUntilExpression (
You can’t perform that action at this time.
0 commit comments