title: Mocha Chai .end() function not being executed
body: <p>I have been trying to write a Mocha chai test for a Nodejs API. It was previously written using Supertest. However, in both cases, the test always passed even though I specify wrong expected parameters.</p>
  <p>Here is the test function using chai</p>
  <pre><code>
  const chai = require('chai');
  const chaiHttp = require('chai-http');
  
  chai.should();
  
  chai.use(chaiHttp);
  
  
  const app = require(&quot;../app&quot;);
  const user = {
    first_name: &quot;Name&quot;,
      last_name: &quot;Lastname&quot;,
      email: &quot;email&quot;,
      password: &quot;password&quot;
  };
  
  describe(&quot;Registration  Test&quot;, () =&gt; {
    it(&quot;Responds with status of registration&quot;, (done) =&gt; {
      chai.request(app)
      .post('/register')
      .send(user)
      .end((err,res) =&gt; {
        if(err) done(err);
        res.should.have.status.eq(200);
        res.body.should.have.property('success').eq(true);
        done();   &lt;------------ Here it doesn't work. It returns For async tests and hooks, ensure &quot;done()&quot; is called error
      });
      done(); &lt;----------- But here it works
  
    });
  
  
  });
  
  
  </code></pre>
  <p>The API responds with a body with properties success, message and status. But no matter what I write in the chai should checks, the test always passes. Also, when I add the done(); inside the end(), it is not being found, and but when I write it outside the end(), it runs. So I assume my code is never entering the .end().</p>