File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 1
1
// Tests are placed alongside files under test.
2
2
// This file does the following:
3
- // 1. Sets the environment to 'production ' so that
3
+ // 1. Sets the environment to 'test ' so that
4
4
// dev-specific babel config in .babelrc doesn't run.
5
5
// 2. Disables Webpack-specific features that Mocha doesn't understand.
6
6
// 3. Registers babel for transpiling our code for testing.
7
7
8
8
// This assures the .babelrc dev config (which includes
9
9
// hot module reloading code) doesn't apply for tests.
10
- process . env . NODE_ENV = 'production' ;
10
+ // Setting NODE_ENV to test instead of production because setting it to production will suppress error messaging
11
+ // and propType validation warnings.
12
+ process . env . NODE_ENV = 'test' ;
11
13
12
14
// Disable webpack-specific features for tests since
13
15
// Mocha doesn't know what to do with them.
You can’t perform that action at this time.
0 commit comments