UNPKG

generator-node-boilerplate

Version:
43 lines (38 loc) 978 B
/* global describe, beforeEach, it */ 'use strict'; var path = require('path'); var helpers = require('yeoman-generator').test; describe('node-boilerplate generator', function() { beforeEach(function(done) { helpers.testDirectory(path.join(__dirname, 'temp'), (function(_this) { return function(err) { if(err) { return done(err); } _this.app = helpers.createGenerator('node-boilerplate:app', [ '../../app' ]); done(); }; })(this)); }); it('creates expected files', function(done) { var expected = [ // add files you expect to exist here. '.editorconfig', '.coffeelint', '.travis.yml', '.bowerrc', 'README.md', 'LICENSE' ]; helpers.mockPrompt(this.app, { 'someOption': true }); this.app.options['skip-install'] = true; this.app.run({}, function() { helpers.assertFile(expected); done(); }); }); });