title: Loading fixtures in sails tests
body: <p>The <a href="http://sailsjs.org/#!/documentation/concepts/Testing" rel="nofollow">docs</a> just say</p>
  
  <pre><code>// here you can load fixtures, etc.
  </code></pre>
  
  <p>I've worked out that I can include </p>
  
  <pre><code>var fixtures = require('./fixtures/models.js');
  </code></pre>
  
  <p>in the bootstrap script, so the full bootstrap script is:</p>
  
  <pre><code>/*
   * Lifts Sails before testing comenses.
   */
  
  var Sails = require('sails');
  var sails;
  
  before(function(done) {
    this.timeout(5000);
  
    Sails.lift({
      // configuration for testing purposes
      environment: 'test',
    }, function(err, server) {
      sails = server;
      if (err) {
        return done(err);
      }
  
      // here you can load fixtures, etc.
      var fixtures = require('./fixtures/models.js');
      done(err, sails);
    });
  });
  
  after(function(done) {
    // here you can clear fixtures, etc.
    Sails.lower(done);
  });
  </code></pre>
  
  <p>I can then reference the fixtures var in the boot script, but I can't reference it in a test. I just get undefined.</p>