Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 6 additions & 12 deletions app/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,18 +90,13 @@ export default class Generator extends Base {

this.log('# Client\n');

this.prompt([{
this.prompt([/*{
type: 'list',
name: 'script',
message: 'What would you like to write scripts with?',
choices: [ 'JavaScript', 'JavaScript + Babel'],
filter: function( val ) {
return {
'JavaScript': 'js',
'JavaScript + Babel': 'babel'
}[val];
}
}, {
choices: ['Babel', 'TypeScript'],
filter: function(val) { return val.toLowerCase(); }
}, */{
type: 'list',
name: 'markup',
message: 'What would you like to write markup with?',
Expand Down Expand Up @@ -134,9 +129,8 @@ export default class Generator extends Base {
}
}], function (answers) {

// also set 'js' to true if using babel
if(answers.script === 'babel') { this.filters.js = true; }
this.filters[answers.script] = true;
this.filters.js = true;
this.filters.babel = true;
this.filters[answers.markup] = true;
this.filters[answers.stylesheet] = true;
this.filters[answers.router] = true;
Expand Down
File renamed without changes.
61 changes: 0 additions & 61 deletions test/test-file-creation.js
Original file line number Diff line number Diff line change
Expand Up @@ -729,66 +729,5 @@ describe('angular-fullstack generator', function () {
}

});

describe('with no preprocessors and no server options', function() {
var testOptions = {
script: 'js',
markup: 'html',
stylesheet: 'css',
router: 'ngroute',
testing: 'jasmine',
odms: [],
auth: false,
oauth: [],
socketio: false,
bootstrap: true,
uibootstrap: true
};

beforeEach(function(done) {
helpers.mockPrompt(gen, testOptions);
done();
});

it('should run client tests successfully', function(done) {
runTest('grunt test:client', this, done);
});

it('should pass jscs', function(done) {
runTest('grunt jscs', this, done);
});

it('should pass lint', function(done) {
runTest('grunt jshint', this, done);
});

it('should run server tests successfully', function(done) {
runTest('grunt test:server', this, done);
});

it('should generate expected files', function (done) {
gen.run(function () {
assert.file(genFiles(testOptions));
done();
});
});

it('should not generate unexpected files', function (done) {
gen.run(function () {
assertOnlyFiles(genFiles(testOptions), done);
});
});

if(!process.env.SKIP_E2E) {
it('should run e2e tests successfully', function (done) {
runTest('grunt test:e2e', this, done, 240000);
});

//it('should run e2e tests successfully for production app', function (done) {
// runTest('grunt test:e2e:prod', this, done, 240000);
//});
}

});
});
});