Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.on('end', function() {
assert.file([].concat(
defaultExpectedFiles,
'app/client/scripts/routes/test_deps.js',
'app/client/templates/test',
'app/client/templates/test/index.hbs'
));
assert.fileContent('app/client/scripts/routes/test_route.js', /App.TestRoute = Ember.Route/);
assert.fileContent('app/client/scripts/routes/test_route.js', /requireLists: \['routes\/test_deps'\]/);
assert.fileContent('app/client/scripts/routes/test_deps.js', /'templates\/test'/);
// gulpfile requirejs modules injection
assert.fileContent('gulpfile.js',
/gulp.task\('build-requirejs',[\s\S]*modules: \[[\s\S]+?\n? {12}\{[\s\S]+name: 'routes\/test_deps',[\s]+exclude: \['app\/common'][\s]+}[\s]+\]/);
done();
it('creates expected files', function () {
assert.file([
'.gitignore',
'gulpfile.babel.js/config.js',
'gulpfile.babel.js/index.js',
'gulpfile.babel.js/tasks/appx.js',
'gulpfile.babel.js/tasks/bundle.js',
'gulpfile.babel.js/tasks/browserSync.js',
'gulpfile.babel.js/tasks/clean.js',
'gulpfile.babel.js/tasks/deploy.js',
'gulpfile.babel.js/tasks/minify.js',
'gulpfile.babel.js/tasks/copy.js',
'gulpfile.babel.js/util/handleErrors.js',
'LICENSE',
'package.json',
'README.md',
'.eslintrc',
'.babelrc',
it('creates expected files', function () {
var expected = [
'package.json',
'.gitignore',
'.gitattributes',
'.jshintrc',
'gulpfile.js',
'app/main.js'
];
assert.file(expected);
});
});
it('creates files', function () {
assert.file([
'package.json',
'.editorconfig',
'index.js',
'README.md',
'LICENSE.md',
'test.js'
]);
});
});
it('creates coffee and cjsx files', function () {
assert.file([
'app/scripts/app.coffee',
'app/scripts/router.cjsx',
'app/scripts/components/layout.cjsx',
'app/scripts/components/home.cjsx',
'gulpfile.coffee'
]);
});
it('creates test files', function() {
assert.file([
'test/karma.conf.js',
'test/protractor.conf.js',
'test/test-main.js'
]);
assert.file([
'test/e2e/demo-spec.js',
'test/e2e/main-spec.js',
'test/unit/demo/app-title-spec.js',
'test/unit/app-spec.js'
]);
});
it('creates less files', function () {
assert.file('src/assets/stylesheets/style.less');
});
bangApi.run(function () {
assert.file('server/api/user/index.js');
assert.file('server/api/user/user.socket.js');
assert.fileContent('server/config/sockets.js', 'require(\'../api/user/user.socket.js\').register(socket);');
done();
});
});
testutil.run(base, function (err) {
assert.file([
'public/templates/ContentTest.dust'
]);
done(err);
});
});
bangFont.run(function () {
assert.file('client/assets/fonts/sushi');
assert.file('client/styles/fonts.scss');
setTimeout(function () {
assert.fileContent('client/styles/fonts.scss', 'url(\'/assets/fonts/sushi/sushi.eot\')');
assert.fileContent('client/styles/fonts.scss', 'url(\'/assets/fonts/sushi/sushi.woff\') format(\'woff\')');
assert.fileContent('client/styles/fonts.scss', 'url(\'/assets/fonts/sushi/sushi.otf\') format(\'opentype\')');
assert.fileContent('client/styles/fonts.scss', 'url(\'/assets/fonts/sushi/sushi.ttf\') format(\'truetype\')');
assert.fileContent('client/styles/fonts.scss', 'url(\'/assets/fonts/sushi/sushi.svg#sushi\') format(\'svg\')');
done();
}, 30);
});