old_contents: describe('slides', function () {
  
    var Dashboard = require('performanceplatform-client.js');
    var Q = require('q');
    var slides = require('../../src/js/slides.js');
    var container = document.createElement('div');
  
    beforeEach(function (done) {
      var deferred = Q.defer();
  
      Dashboard.prototype.getConfig = function () {
        return deferred.promise;
      };
  
      slides(container).then(function () {
        done();
      });
      deferred.resolve({
        'title': '"Dashboard title"'
      });
    });
  
    it('should retrieve dashboard config', function () {
      container.innerHTML.should.contain('Performance data for "Dashboard title"');
    });
  
  });
  
  
new_contents: describe('slides', function () {
  
    var Dashboard = require('performanceplatform-client.js');
    var Q = require('q');
    var slides = require('../../src/js/slides.js');
    var container = document.createElement('div');
  
    beforeEach(function (done) {
      var deferred = Q.defer();
  
      sinon.stub(Dashboard.prototype, 'getConfig').returns(deferred.promise);
  
      slides(container).then(function () {
        done();
      });
      deferred.resolve({
        'title': '"Dashboard title"'
      });
    });
  
    it('should retrieve dashboard config', function () {
      container.innerHTML.should.contain('Performance data for "Dashboard title"');
    });
  
  });
  
  
subject: Use sinon to stub method