title: How to verify the response key in chai
body: <p>I have a response body as</p>
  
  <pre><code>[{
    "_id": "56fc22f625311b661becefb5",
    “activities”: [...],
    "lastName": “patrick”,
    "firstName": "John”,
    "city": “Chennai”,
    "state": “TAMILNADU”
  }, {
    "_id": "56fc22f625311b661becefb6",
    “activities”: [...],
    "lastName": “sparrow”,
    "firstName": "John",
    "city": “Chennai”,
    "state": “TAMILNADU”
  }]
  </code></pre>
  
  <p>when I make an API call via supertest in Mocha, I have to validate whether the response body's key has firstName,lastName and state and the value of state as TAMILNADU in chai.</p>
  
  <p>How to do it, I tried </p>
  
  <pre><code>res.body.should.have.property("lastName");
  res.body.should.have.property("state"); 
  </code></pre>
  
  <p>but getting an error as </p>
  
  <blockquote>
    <p>Uncaught AssertionError: expected [ Array(1) ] to have a property 'firstName'</p>
  </blockquote>