I'm working on a compound js app. In environments/test.js I have exported a variable as follows:
app.host = "http://mysite.com"
When I run the app as below:
NODE_ENV=test node .
I could access the value of host by giving app.host. Everything is fine till here.
I'm using mocha for testing. When I try to access app.host from my test file, I'm getting an error saying,
ReferenceError: app is not defined.
Any idea on how to access the variables from environment/test.js file from test/*.js files would be helpful. Thanks in advance.