title: Timeout when using Mockgoose/Mongoose save/create with Mocha and Chai-Expect
body: <p>I am getting Timeout running Unit Tests with <code>Mocha</code>, <code>Chai</code> and <code>Mockgoose</code></p>
  
  <p>I have a function <code>Assessment.NewAssessment(assessmentDetails)</code> that will save the assessment in the DB.</p>
  
  <p><strong>NOTE</strong>: `Assessment.NewAssessment returns a promise (It is an async function)</p>
  
  <p>Here is what I did so far:</p>
  
  <pre><code>require('assert');
  let chai = require('chai');
  let chaiAsPromised = require("chai-as-promised");
  chai.use(chaiAsPromised);
  let expect = chai.expect;
  let Assessment = require('../models/Assessment');
  let CustomError = require('../CustomError');
  
  let mongoose = new (require('mongoose').Mongoose)();
  let Mockgoose = require('mockgoose').Mockgoose;
  let mockgoose = new Mockgoose(mongoose);
  
  before(function (done) {
      mockgoose.prepareStorage().then(async function () {
          mongoose.connect(
              'mongodb://127.0.0.1/' + process.env.DB_NAME + '_test?replicaSet=rs0',
              {useNewUrlParser: true},
              function (err) {
                  done(err);
              });
      });
  });
  
  describe('Class Assessment', function () {
      describe('Function GetAll', function () {
          it('Throw an error with code 400 for non-object parameters', () =&gt; {
              return expect(Assessment.GetAll('test'))
                  .to.be.eventually.rejectedWith(CustomError)
                  .and.have.property('code', 400);
          });
  
          it('Successfully creating an assessment', async () =&gt; {
              let assessmentDetails = {
                  name: 'test',
                  createdBy: mongoose.Types.ObjectId(),
              };
              let assessment = await Assessment.NewAssessment(assessmentDetails)
  
              return expect(assessment).to.be.an('object');
          });
      });
  });
  </code></pre>
  
  <p>In <code>Assessment.js</code>:</p>
  
  <pre><code>static async NewAssessment(assessmentDetails) {
      if (!assessmentDetails || typeof assessmentDetails !== 'object') {
          throw new CustomError('assessmentDetails is not defined.', HttpStatus.BAD_REQUEST);
      }
  
      return await new Assessment(assessmentDetails).save();
  }
  </code></pre>
  
  <p>The output of running <code>mocha --timeout 120000</code> is:</p>
  
  <pre><code>Error: Timeout of 120000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves.
  </code></pre>
  
  <p>What am I doing wrong here?</p>