title: How can I use describe in a loop?
body: <p>I'm trying to write test cases that test a chatbot and I need to check many things in <code>it</code> blocks on every response. So the flow right now is that I send many messages and I'm trying to have a describe statement inside the forEach loop but for some reason this isn't working. None of the tests in the <code>it</code> blocks are running.</p>
  
  <pre><code>const body = ['hi', 'transfer 20 sms', 'no', 'no', 'first one', 'first one']
  
  describe('API', () =&gt; {
        describe('Basic flow', () =&gt; {
          body.forEach((v, i) =&gt; {
            describe(`Should get response for message #${i + 1}`, () =&gt; {
              return agent.post('/watson/send').send({
                'content': {
                  'userInput': v,
                  'userDial': '123456'
                }
              }).then(response =&gt; {
                it('Body should exist', done =&gt; {
                  // this part doesnt work
                  const { body } = response
                  const { text } = response.body.reply
                  expect(_.isEmpty(body)).to.equal(false)
                  done()
                })
              })
            })
          })
        })
      })
  </code></pre>
  
  <p>My understanding is that this doesn't work because mocha doesn't find <code>it</code> blocks inside promises. I can't figure out how to restructure this so as to have multiple <code>it</code> blocks that test the same result of the API.</p>