}else { response.should.have.property('statusCode'); (response.statusCode).should.be.equal(200); body.should.have.property('template_api'); body.template_api.should.have.property('version'); (body.template_api.version).should.be.equal(indexTemplate.version); done(); done(error); }else { response.should.have.property('statusCode'); (response.statusCode).should.be.equal(200); body.should.have.property('hits'); body.hits.should.have.property('total'); (body.hits.total).should.be.equal(10);