Skip to content

Commit

Permalink
Tests: Move promise/A+ adapters for tests to dedicated folder
Browse files Browse the repository at this point in the history
  • Loading branch information
markelog committed Jun 11, 2016
1 parent f80ae67 commit a4474c9
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 13 deletions.
10 changes: 5 additions & 5 deletions build/tasks/promises_aplus_tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,19 @@ module.exports = function( grunt ) {
var spawnTest = require( "./lib/spawn_test.js" );

grunt.registerTask( "promises_aplus_tests",
[ "promises_aplus_tests_deferred", "promises_aplus_tests_when" ] );
[ "promises_aplus_tests:deferred", "promises_aplus_tests:when" ] );

grunt.registerTask( "promises_aplus_tests_deferred", function() {
grunt.registerTask( "promises_aplus_tests:deferred", function() {
spawnTest( this.async(),
"./node_modules/.bin/promises-aplus-tests",
"test/promises_aplus_adapter_deferred.js"
"test/promises_aplus_adapters/deferred.js"
);
} );

grunt.registerTask( "promises_aplus_tests_when", function() {
grunt.registerTask( "promises_aplus_tests:when", function() {
spawnTest( this.async(),
"./node_modules/.bin/promises-aplus-tests",
"test/promises_aplus_adapter_when.js"
"test/promises_aplus_adapters/when.js"
);
} );
};
3 changes: 3 additions & 0 deletions test/node_smoke_tests/.eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"env": {
"node": true
},
"parserOptions": {
"ecmaVersion": 6
},
"extends": "../.eslintrc",
"root": true
}
7 changes: 7 additions & 0 deletions test/promises_aplus_adapters/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"env": {
"node": true
},
"extends": "../.eslintrc",
"root": true
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* jshint node: true */

"use strict";

require( "jsdom" ).env( "", function( errors, window ) {
Expand All @@ -8,9 +6,9 @@ require( "jsdom" ).env( "", function( errors, window ) {
return;
}

var jQuery = require( ".." )( window );
var jQuery = require( "../../" )( window );

exports.deferred = function() {
module.exports.deferred = function() {
var deferred = jQuery.Deferred();

return {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* jshint node: true */

"use strict";

require( "jsdom" ).env( "", function( errors, window ) {
Expand All @@ -8,9 +6,9 @@ require( "jsdom" ).env( "", function( errors, window ) {
return;
}

var jQuery = require( ".." )( window );
var jQuery = require( "../../" )( window );

exports.deferred = function() {
module.exports.deferred = function() {
var adopted, promised,
obj = {
resolve: function() {
Expand Down

0 comments on commit a4474c9

Please sign in to comment.