New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add server testing in node 0.10, 0.12 and iojs #2729

Merged
merged 2 commits into from Aug 23, 2015

Conversation

Projects
None yet
2 participants
@SergioCrisostomo
Member

SergioCrisostomo commented Aug 7, 2015

CI testing of the server build (closes #2700).

Had to add some xit : it in the specs because they will now run in node environment and document and window are not there.

Added also some Travis optimizing and Safari 8 testing for Browser specs.

To run server specs locally we can use grunt server.

Tested all this in Travis and got green for Browser and node tests.

Show outdated Hide outdated Specs/Core/Core.js
@@ -610,7 +610,7 @@ describe('instanceOf', function(){
});
// todo(ibolmo)
if (window.Element && Element.set) it("should return true for Element instances", function(){
if (typeof window != 'undefined' && window.Element && Element.set) it("should return true for Element instances", function(){

This comment has been minimized.

@arian

arian Aug 10, 2015

Member

do the typeof window check in the dit definition?

@arian

arian Aug 10, 2015

Member

do the typeof window check in the dit definition?

Show outdated Hide outdated Tests/gruntfile-options.js
@@ -21,6 +26,14 @@ var packagerOptions = {
src: ymlPackage.sources,
dest: 'mootools-nocompat.js'
},
server: {

This comment has been minimized.

@arian

arian Aug 10, 2015

Member

indentation.

@arian

arian Aug 10, 2015

Member

indentation.

Show outdated Hide outdated package.json
"karma-script-launcher": "~0.1.0",
"karma-sinon": "~1.0.2",
"load-grunt-tasks": "~0.4.0",
"requirejs": "~2.1.11"

This comment has been minimized.

@arian

arian Aug 10, 2015

Member

Why do we need this?

@arian

arian Aug 10, 2015

Member

Why do we need this?

Show outdated Hide outdated Tests/gruntfile-options.js
var serverBuild = {
modules: ['Core/Core', 'Core/Array', 'Core/String', 'Core/Number', 'Core/Function', 'Core/Object', 'Core/Class', 'Core/Class.Extras', 'Core/JSON'],
specFiles: ['Specs/Core/*.js', 'Specs/Core/*.js', 'Specs/Core/*.js', 'Specs/Core/*.js', 'Specs/Core/*.js'],
strip: ['1.2compat', '1.3compat', '1.4compat', '*compat', 'IE', 'ltIE8', 'ltIE9', '!ES5', '!ES5-bind'/*, '!ES6'*/, 'webkit', 'ltFF4']

This comment has been minimized.

@arian

arian Aug 10, 2015

Member

You just defined this in Tests/dist-tasks.json as well...

@arian

arian Aug 10, 2015

Member

You just defined this in Tests/dist-tasks.json as well...

@SergioCrisostomo

This comment has been minimized.

Show comment
Hide comment
@SergioCrisostomo

SergioCrisostomo Aug 10, 2015

Member

@arian thanks for reviewing.

Updated removing unused requirejs dependency that was there since old days and fixed other things that @arian pointed out.

Member

SergioCrisostomo commented Aug 10, 2015

@arian thanks for reviewing.

Updated removing unused requirejs dependency that was there since old days and fixed other things that @arian pointed out.

@SergioCrisostomo SergioCrisostomo added this to the 1.5.2 milestone Aug 15, 2015

@SergioCrisostomo

This comment has been minimized.

Show comment
Hide comment
@SergioCrisostomo

SergioCrisostomo Aug 22, 2015

Member

@arian (or anyone else) can we merge this?

Member

SergioCrisostomo commented Aug 22, 2015

@arian (or anyone else) can we merge this?

var div = document.createElement('div');
expect(typeOf(div)).toEqual('element');
});
// todo(ibolmo)
if (window.Elements) it("should return 'elements' for Elements", function(){
if (typeof window != 'undefined' && window.Elements) dit("should return 'elements' for Elements", function(){

This comment has been minimized.

@arian

arian Aug 23, 2015

Member

isn't this if included in the dit function?

@arian

arian Aug 23, 2015

Member

isn't this if included in the dit function?

tasks = options.travis.build == 'server' ? tasks.concat('server-jasmine-runner') : usePhantom ? tasks.concat('karma:continuous') : tasks.concat('karma:sauceTask');
// to run only server specs and avoid running browser specs for in the different versions of node and iojs
if (options.travis.build && options.travis.build != 'server' && process.version.slice(1, 5) != '0.10') tasks = [];

This comment has been minimized.

@arian

arian Aug 23, 2015

Member

👍

@arian

arian Aug 23, 2015

Member

👍

arian added a commit that referenced this pull request Aug 23, 2015

Merge pull request #2729 from SergioCrisostomo/server-build-specs
add server testing in node 0.10, 0.12 and iojs

@arian arian merged commit cb62f08 into mootools:master Aug 23, 2015

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@SergioCrisostomo SergioCrisostomo deleted the SergioCrisostomo:server-build-specs branch Dec 1, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment