File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4444 run : npm install
4545
4646 # - name: Format ✨
47- # run: npm run test.format
47+ # run: npm run test.format
4848
4949 - name : Lint ✨
5050 run : npm run test.lint
Original file line number Diff line number Diff line change @@ -5,6 +5,8 @@ const isReadable = isDev || isTest
55const ProductionCompress = {
66 global_defs : {
77 // remove dev and test specific code for production
8+ "process.env.NODE_ENV" : process . env . NODE_ENV || "production" ,
9+ "process.env.BABEL_ENV" : process . env . BABEL_ENV || process . env . NODE_ENV || "production" ,
810 "@atom.inSpecMode" : ! isTest ? "() => false" : "() => true" ,
911 "@atom.inDevMode" : ! isDev ? "() => false" : "() => true" ,
1012 } ,
Original file line number Diff line number Diff line change @@ -11,6 +11,8 @@ describe("Terser-Config-Atomic", () => {
1111
1212 expect ( typeof TerserOptions ) . toBe ( "object" )
1313 expect ( TerserOptions . compress . global_defs ) . toEqual ( {
14+ "process.env.NODE_ENV" : "production" ,
15+ "process.env.BABEL_ENV" : "production" ,
1416 "@atom.inSpecMode" : "() => false" ,
1517 "@atom.inDevMode" : "() => false" ,
1618 } )
@@ -35,6 +37,8 @@ describe("Terser-Config-Atomic", () => {
3537
3638 expect ( typeof TerserOptions ) . toBe ( "object" )
3739 expect ( TerserOptions . compress . global_defs ) . toEqual ( {
40+ "process.env.NODE_ENV" : "test" ,
41+ "process.env.BABEL_ENV" : "test" ,
3842 "@atom.inSpecMode" : "() => true" ,
3943 "@atom.inDevMode" : "() => false" ,
4044 } )
You can’t perform that action at this time.
0 commit comments