Closed refextu closed 9 years ago
the following documentation is missleading, but obvious passing envs to the app ist not possible, when the app is already initialized.
var Session = require('supertest-session')({ app: require('../../path/to/app'), envs: { NODE_ENV: 'development' } });
what you have to do work with envs consistently:
process.env['NODE_ENV'] = "development"; var Session = require('supertest-session')({ app: require('../../path/to/app'), });
I would suggest to depreciate the use of your envs, cause the status of envs changes over runtime.
Absolutely! If you're willing to submit a PR to this effect, it should be a pretty uncontroversial merge.
the following documentation is missleading, but obvious passing envs to the app ist not possible, when the app is already initialized.
what you have to do work with envs consistently:
I would suggest to depreciate the use of your envs, cause the status of envs changes over runtime.