title: How to set timeout on before hook in mocha?
body: <p>I want to set timeout value on before hook in mocha test cases. I know I can do that by adding <code>-t 10000</code> on the command line of mocha but this will change every test cases timeout value. I want to find a way to change the timeout programmatically below is my code:</p>
  
  <pre><code>describe('test  ', () =&gt; {
  
    before((done) =&gt; {
          this.timeout(10000);
           ...
  </code></pre>
  
  <p>it will complain about the line <code>this.timeout(1000)</code> that <code>timeout</code> is not defined. How to set the timeout on before hook.</p>