🌐 AI搜索 & 代理 主页
Skip to content

Commit 34f2563

Browse files
committed
Deferred: Backwards-compatible standards interoperability
Fixes gh-1722 Closes gh-1996 (cherry picked from commit 555a50d)
1 parent 9d255b3 commit 34f2563

File tree

9 files changed

+698
-114
lines changed

9 files changed

+698
-114
lines changed

Gruntfile.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ module.exports = function( grunt ) {
5353
"sizzle/dist": "sizzle/dist",
5454
"sizzle/LICENSE.txt": "sizzle/LICENSE.txt",
5555

56+
"npo/npo.js": "native-promise-only/npo.js",
57+
5658
"qunit/qunit.js": "qunitjs/qunit/qunit.js",
5759
"qunit/qunit.css": "qunitjs/qunit/qunit.css",
5860
"qunit/LICENSE.txt": "qunitjs/LICENSE.txt",
@@ -158,7 +160,8 @@ module.exports = function( grunt ) {
158160
// Only defined for master at this time, but kept for cross-branch consistency
159161
grunt.registerTask( "test_fast", [] );
160162

161-
grunt.registerTask( "test", [ "test_fast" ] );
163+
// gh-2133 TODO: cherry-pick 76df9e4e389d80bff410a9e5f08b848de1d21a2f for promises-aplus-tests
164+
grunt.registerTask( "test", [ "test_fast"/*, "promises-aplus-tests"*/ ] );
162165

163166
// Short list as a high frequency watch task
164167
grunt.registerTask( "dev", [ "build:*:*", "lint", "uglify", "remove_map_comment", "dist:*" ] );
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
module.exports = function( grunt ) {
2+
3+
"use strict";
4+
5+
var spawn = require( "child_process" ).spawn;
6+
7+
grunt.registerTask( "promises-aplus-tests", function() {
8+
var done = this.async();
9+
spawn(
10+
"node",
11+
[
12+
"./node_modules/.bin/promises-aplus-tests",
13+
"test/promises-aplus-adapter.js"
14+
],
15+
{ stdio: "inherit" }
16+
).on( "close", function( code ) {
17+
done( code === 0 );
18+
});
19+
});
20+
};

external/npo/npo.js

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

external/requirejs/require.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** vim: et:ts=4:sw=4:sts=4
2-
* @license RequireJS 2.1.14 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
2+
* @license RequireJS 2.1.15 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
33
* Available via the MIT or new BSD license.
44
* see: http://github.com/jrburke/requirejs for details
55
*/
@@ -12,7 +12,7 @@ var requirejs, require, define;
1212
(function (global) {
1313
var req, s, head, baseElement, dataMain, src,
1414
interactiveScript, currentlyAddingScript, mainScript, subPath,
15-
version = '2.1.14',
15+
version = '2.1.15',
1616
commentRegExp = /(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg,
1717
cjsRequireRegExp = /[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g,
1818
jsSuffixRegExp = /\.js$/,

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@
4343
"grunt-npmcopy": "0.1.0",
4444
"gzip-js": "0.3.2",
4545
"load-grunt-tasks": "1.0.0",
46+
"native-promise-only": "0.7.6-a",
4647
"npm": "2.1.12",
48+
"promises-aplus-tests": "2.1.0",
49+
"q": "1.1.2",
4750
"qunitjs": "1.17.1",
4851
"requirejs": "2.1.15",
4952
"sinon": "1.12.2",

0 commit comments

Comments
 (0)