title: How to get response's body with mocha / node.js
body: <p>I'm very new to mocha / omf. I have the basic test below:  </p>
  
  <pre><code>omf('http://localhost:7000', function(client) {
    client.get('/apps', function(response){
      response.has.statusCode(200);
      response.has.body('["test1","test2"]');
    });
  });
  </code></pre>
  
  <p>I'd like to check if the value "test2" is among the list returned but I cannot figure out how this is feasible. I'm thinking of something like:</p>
  
  <pre><code>omf('http://localhost:7000', function(client) {
    client.get('/apps', function(response){
      response.has.statusCode(200);
      // response.body.split.contains("test2"); // Something like that
    });
  });
  </code></pre>
  
  <p>Can I access response.body and then parse the string ?</p>
  
  <p>** UPDATE **</p>
  
  <p>I've tried to test with mocha, just a simple status code:  </p>
  
  <pre><code>request = require("request");
  
  describe('Applications API', function(){
    it('Checks existence of test application', function(done){
      request
        .get('http://localhost:7000/apps')
        .expect(200, done);
    });
  });
  </code></pre>
  
  <p>but I got the following error:</p>
  
  <blockquote>
    <p>TypeError: Object # has no method 'expect'</p>
  </blockquote>
  
  <p>Any idea ? Does mocha need to have additional addons ?</p>