Skip to content

Commit

Permalink
upd: deps & benchmark
Browse files Browse the repository at this point in the history
  • Loading branch information
ysmood committed Feb 24, 2016
1 parent 5b7ac89 commit f33bd5e
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 25 deletions.
2 changes: 2 additions & 0 deletions benchmark/testCount.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@ module.exports = function (name) {
return s;
}, "");

// remove terminal color codes
out = out.replace(/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]/g, "");

// search the stdout "failing 11", "failed 23"
var count = [/^junit cli > failed (\d+)$/mg, /^\s*(\d+) failing$/mg]
.reduce(function (s, reg) {
var ms = out.match(reg);
Expand Down
17 changes: 9 additions & 8 deletions docs/readme.jst.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,19 @@ For more details see the [benchmark/readme.md](benchmark/readme.md). There are t
Node v5.6.0
OS darwin
Arch x64
CPU Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
CPU Intel(R) Core(TM) i7-4850HQ CPU @ 2.30GHz
```

| name | unit tests | 1ms async task | optional helpers | helpers | min js |
| ---- | ---------- | -------------- | ---------------- | ------- | ------ |
| [yaku][]@0.11.6 || 330ms / 106MB || 29 | <%= doc.size %>KB |
| [bluebird][]@3.3.1 | x (18 failing) | 265ms / 88MB | partial | 100 | 52.2KB |
| [es6-promise][]@3.1.2 | x (52 failing) | 426ms / 113MB | x | 10 | 6.3KB |
| [native][]@0.12.4 | x ( 4 failing) | 590ms / 173MB | x | 13 | 0KB |
| [core-js][]@2.1.0 | x ( 4 failing) | 838ms / 198MB | x | 11 | 13.9KB |
| [es6-shim][]@0.34.4 || 950ms / 145MB | x | 12 | 130.8KB |
| [q][]@1.4.1 | x (47 failing) | 1599ms / 425MB | x | 74 | 15.4KB |
| [yaku][]@0.13.1 || 337ms / 106MB || 31 | 3.2KB |
| [bluebird][]@3.3.1 | x (26 failing) | 258ms / 88MB | partial | 100 | 52.2KB |
| [es6-promise][]@3.1.2 | x (39 failing) | 457ms / 112MB | x | 10 | 6.3KB |
| [native][]@0.13.2 | x (7 failing) | 653ms / 168MB | x | 13 | 0KB |
| [core-js][]@2.1.1 | x (2 failing) | 1014ms / 197MB | x | 11 | 18.7KB |
| [es6-shim][]@0.34.4 || 927ms / 145MB | x | 12 | 130.8KB |
| [q][]@1.4.1 | x (68 failing) | 1609ms / 426MB | x | 74 | 15.4KB |


- **Helpers**: extra methods that help with your promise programming, such as
async flow control helpers, debug helpers. For more details: [docs/debugHelperComparison.md][].
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,19 @@
],
"devDependencies": {
"bluebird": "3.3.1",
"core-js": "2.1.0",
"core-js": "2.1.1",
"es6-promise": "3.1.2",
"es6-shim": "0.34.4",
"eslint": "2.0.0",
"junit": "1.1.3",
"eslint": "2.2.0",
"junit": "1.2.0",
"mocha": "2.4.5",
"nokit": "0.17.2",
"promises-aplus-tests": "*",
"promises-es6-tests": "*",
"q": "1.4.1",
"setprototypeof": "1.0.1",
"uglify-js": "2.6.1",
"webpack": "1.12.13"
"uglify-js": "2.6.2",
"webpack": "1.12.14"
},
"eslintConfig": {
"env": {
Expand Down
19 changes: 10 additions & 9 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ideas: [docs/lazyTree.md][].

# Features

- The minified file is only 3.3KB (2KB gzipped)
- The minified file is only 3.2KB (2KB gzipped)
- [Better "possibly unhandled rejection" and "long stack trace"][docs/debugHelperComparison.md] than [Bluebird][]
- Much better performance than the native Promise
- 100% compliant with Promises/A+ specs and nearly 100% compliant with ES6 specs
Expand Down Expand Up @@ -75,18 +75,19 @@ For more details see the [benchmark/readme.md](benchmark/readme.md). There are t
Node v5.6.0
OS darwin
Arch x64
CPU Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
CPU Intel(R) Core(TM) i7-4850HQ CPU @ 2.30GHz
```

| name | unit tests | 1ms async task | optional helpers | helpers | min js |
| ---- | ---------- | -------------- | ---------------- | ------- | ------ |
| [yaku][]@0.11.6 || 330ms / 106MB || 29 | 3.3KB |
| [bluebird][]@3.3.1 | x (18 failing) | 265ms / 88MB | partial | 100 | 52.2KB |
| [es6-promise][]@3.1.2 | x (52 failing) | 426ms / 113MB | x | 10 | 6.3KB |
| [native][]@0.12.4 | x ( 4 failing) | 590ms / 173MB | x | 13 | 0KB |
| [core-js][]@2.1.0 | x ( 4 failing) | 838ms / 198MB | x | 11 | 13.9KB |
| [es6-shim][]@0.34.4 || 950ms / 145MB | x | 12 | 130.8KB |
| [q][]@1.4.1 | x (47 failing) | 1599ms / 425MB | x | 74 | 15.4KB |
| [yaku][]@0.13.1 || 337ms / 106MB || 31 | 3.2KB |
| [bluebird][]@3.3.1 | x (26 failing) | 258ms / 88MB | partial | 100 | 52.2KB |
| [es6-promise][]@3.1.2 | x (39 failing) | 457ms / 112MB | x | 10 | 6.3KB |
| [native][]@0.13.2 | x (7 failing) | 653ms / 168MB | x | 13 | 0KB |
| [core-js][]@2.1.1 | x (2 failing) | 1014ms / 197MB | x | 11 | 18.7KB |
| [es6-shim][]@0.34.4 || 927ms / 145MB | x | 12 | 130.8KB |
| [q][]@1.4.1 | x (68 failing) | 1609ms / 426MB | x | 74 | 15.4KB |


- **Helpers**: extra methods that help with your promise programming, such as
async flow control helpers, debug helpers. For more details: [docs/debugHelperComparison.md][].
Expand Down
4 changes: 1 addition & 3 deletions test/getPromise.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ var map = {
},

"core-js": function () {
require("core-js/modules/es6.promise.js");

var Promise = global.Promise;
var Promise = require("core-js/fn/promise");
map["core-js"].optionalHelper = "x";
map["core-js"].helper = propSize(Promise) + propSize(Promise.prototype);

Expand Down

0 comments on commit f33bd5e

Please sign in to comment.