I am trying to set the test database for the testing purpose, but its not working.
I am trying to connect to mongodb using mongoose, but finding problem in connection er
If we don't want to define the path of the .env file like this,
require('dotenv').config({ path: 'ENV_FILENAME' });
we can place .env file in the same place as our main file, which was App.js in my case. So we could directly write
require('dotenv').config()