mirror of
https://github.com/actions/setup-java.git
synced 2025-04-20 09:56:46 +00:00
Fix.
This commit is contained in:
parent
596a6da241
commit
c1a589c5b6
7078 changed files with 1882834 additions and 319 deletions
1
node_modules/deep-is/.npmignore
generated
vendored
Normal file
1
node_modules/deep-is/.npmignore
generated
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
node_modules
|
6
node_modules/deep-is/.travis.yml
generated
vendored
Normal file
6
node_modules/deep-is/.travis.yml
generated
vendored
Normal file
|
@ -0,0 +1,6 @@
|
|||
language: node_js
|
||||
node_js:
|
||||
- 0.4
|
||||
- 0.6
|
||||
- 0.8
|
||||
- 0.10
|
22
node_modules/deep-is/LICENSE
generated
vendored
Normal file
22
node_modules/deep-is/LICENSE
generated
vendored
Normal file
|
@ -0,0 +1,22 @@
|
|||
Copyright (c) 2012, 2013 Thorsten Lorenz <thlorenz@gmx.de>
|
||||
Copyright (c) 2012 James Halliday <mail@substack.net>
|
||||
Copyright (c) 2009 Thomas Robinson <280north.com>
|
||||
|
||||
This software is released under the MIT license:
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
70
node_modules/deep-is/README.markdown
generated
vendored
Normal file
70
node_modules/deep-is/README.markdown
generated
vendored
Normal file
|
@ -0,0 +1,70 @@
|
|||
deep-is
|
||||
==========
|
||||
|
||||
Node's `assert.deepEqual() algorithm` as a standalone module. Exactly like
|
||||
[deep-equal](https://github.com/substack/node-deep-equal) except for the fact that `deepEqual(NaN, NaN) === true`.
|
||||
|
||||
This module is around [5 times faster](https://gist.github.com/2790507)
|
||||
than wrapping `assert.deepEqual()` in a `try/catch`.
|
||||
|
||||
[](http://ci.testling.com/thlorenz/deep-is)
|
||||
|
||||
[](http://travis-ci.org/thlorenz/deep-is)
|
||||
|
||||
example
|
||||
=======
|
||||
|
||||
``` js
|
||||
var equal = require('deep-is');
|
||||
console.dir([
|
||||
equal(
|
||||
{ a : [ 2, 3 ], b : [ 4 ] },
|
||||
{ a : [ 2, 3 ], b : [ 4 ] }
|
||||
),
|
||||
equal(
|
||||
{ x : 5, y : [6] },
|
||||
{ x : 5, y : 6 }
|
||||
)
|
||||
]);
|
||||
```
|
||||
|
||||
methods
|
||||
=======
|
||||
|
||||
var deepIs = require('deep-is')
|
||||
|
||||
deepIs(a, b)
|
||||
---------------
|
||||
|
||||
Compare objects `a` and `b`, returning whether they are equal according to a
|
||||
recursive equality algorithm.
|
||||
|
||||
install
|
||||
=======
|
||||
|
||||
With [npm](http://npmjs.org) do:
|
||||
|
||||
```
|
||||
npm install deep-is
|
||||
```
|
||||
|
||||
test
|
||||
====
|
||||
|
||||
With [npm](http://npmjs.org) do:
|
||||
|
||||
```
|
||||
npm test
|
||||
```
|
||||
|
||||
license
|
||||
=======
|
||||
|
||||
Copyright (c) 2012, 2013 Thorsten Lorenz <thlorenz@gmx.de>
|
||||
Copyright (c) 2012 James Halliday <mail@substack.net>
|
||||
|
||||
Derived largely from node's assert module, which has the copyright statement:
|
||||
|
||||
Copyright (c) 2009 Thomas Robinson <280north.com>
|
||||
|
||||
Released under the MIT license, see LICENSE for details.
|
11
node_modules/deep-is/example/cmp.js
generated
vendored
Normal file
11
node_modules/deep-is/example/cmp.js
generated
vendored
Normal file
|
@ -0,0 +1,11 @@
|
|||
var equal = require('../');
|
||||
console.dir([
|
||||
equal(
|
||||
{ a : [ 2, 3 ], b : [ 4 ] },
|
||||
{ a : [ 2, 3 ], b : [ 4 ] }
|
||||
),
|
||||
equal(
|
||||
{ x : 5, y : [6] },
|
||||
{ x : 5, y : 6 }
|
||||
)
|
||||
]);
|
102
node_modules/deep-is/index.js
generated
vendored
Normal file
102
node_modules/deep-is/index.js
generated
vendored
Normal file
|
@ -0,0 +1,102 @@
|
|||
var pSlice = Array.prototype.slice;
|
||||
var Object_keys = typeof Object.keys === 'function'
|
||||
? Object.keys
|
||||
: function (obj) {
|
||||
var keys = [];
|
||||
for (var key in obj) keys.push(key);
|
||||
return keys;
|
||||
}
|
||||
;
|
||||
|
||||
var deepEqual = module.exports = function (actual, expected) {
|
||||
// enforce Object.is +0 !== -0
|
||||
if (actual === 0 && expected === 0) {
|
||||
return areZerosEqual(actual, expected);
|
||||
|
||||
// 7.1. All identical values are equivalent, as determined by ===.
|
||||
} else if (actual === expected) {
|
||||
return true;
|
||||
|
||||
} else if (actual instanceof Date && expected instanceof Date) {
|
||||
return actual.getTime() === expected.getTime();
|
||||
|
||||
} else if (isNumberNaN(actual)) {
|
||||
return isNumberNaN(expected);
|
||||
|
||||
// 7.3. Other pairs that do not both pass typeof value == 'object',
|
||||
// equivalence is determined by ==.
|
||||
} else if (typeof actual != 'object' && typeof expected != 'object') {
|
||||
return actual == expected;
|
||||
|
||||
// 7.4. For all other Object pairs, including Array objects, equivalence is
|
||||
// determined by having the same number of owned properties (as verified
|
||||
// with Object.prototype.hasOwnProperty.call), the same set of keys
|
||||
// (although not necessarily the same order), equivalent values for every
|
||||
// corresponding key, and an identical 'prototype' property. Note: this
|
||||
// accounts for both named and indexed properties on Arrays.
|
||||
} else {
|
||||
return objEquiv(actual, expected);
|
||||
}
|
||||
};
|
||||
|
||||
function isUndefinedOrNull(value) {
|
||||
return value === null || value === undefined;
|
||||
}
|
||||
|
||||
function isArguments(object) {
|
||||
return Object.prototype.toString.call(object) == '[object Arguments]';
|
||||
}
|
||||
|
||||
function isNumberNaN(value) {
|
||||
// NaN === NaN -> false
|
||||
return typeof value == 'number' && value !== value;
|
||||
}
|
||||
|
||||
function areZerosEqual(zeroA, zeroB) {
|
||||
// (1 / +0|0) -> Infinity, but (1 / -0) -> -Infinity and (Infinity !== -Infinity)
|
||||
return (1 / zeroA) === (1 / zeroB);
|
||||
}
|
||||
|
||||
function objEquiv(a, b) {
|
||||
if (isUndefinedOrNull(a) || isUndefinedOrNull(b))
|
||||
return false;
|
||||
|
||||
// an identical 'prototype' property.
|
||||
if (a.prototype !== b.prototype) return false;
|
||||
//~~~I've managed to break Object.keys through screwy arguments passing.
|
||||
// Converting to array solves the problem.
|
||||
if (isArguments(a)) {
|
||||
if (!isArguments(b)) {
|
||||
return false;
|
||||
}
|
||||
a = pSlice.call(a);
|
||||
b = pSlice.call(b);
|
||||
return deepEqual(a, b);
|
||||
}
|
||||
try {
|
||||
var ka = Object_keys(a),
|
||||
kb = Object_keys(b),
|
||||
key, i;
|
||||
} catch (e) {//happens when one is a string literal and the other isn't
|
||||
return false;
|
||||
}
|
||||
// having the same number of owned properties (keys incorporates
|
||||
// hasOwnProperty)
|
||||
if (ka.length != kb.length)
|
||||
return false;
|
||||
//the same set of keys (although not necessarily the same order),
|
||||
ka.sort();
|
||||
kb.sort();
|
||||
//~~~cheap key test
|
||||
for (i = ka.length - 1; i >= 0; i--) {
|
||||
if (ka[i] != kb[i])
|
||||
return false;
|
||||
}
|
||||
//equivalent values for every corresponding key, and
|
||||
//~~~possibly expensive deep test
|
||||
for (i = ka.length - 1; i >= 0; i--) {
|
||||
key = ka[i];
|
||||
if (!deepEqual(a[key], b[key])) return false;
|
||||
}
|
||||
return true;
|
||||
}
|
90
node_modules/deep-is/package.json
generated
vendored
Normal file
90
node_modules/deep-is/package.json
generated
vendored
Normal file
|
@ -0,0 +1,90 @@
|
|||
{
|
||||
"_from": "deep-is@~0.1.3",
|
||||
"_id": "deep-is@0.1.3",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=",
|
||||
"_location": "/deep-is",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "deep-is@~0.1.3",
|
||||
"name": "deep-is",
|
||||
"escapedName": "deep-is",
|
||||
"rawSpec": "~0.1.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "~0.1.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/optionator"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz",
|
||||
"_shasum": "b369d6fb5dbc13eecf524f91b070feedc357cf34",
|
||||
"_spec": "deep-is@~0.1.3",
|
||||
"_where": "E:\\github\\setup-java\\node_modules\\optionator",
|
||||
"author": {
|
||||
"name": "Thorsten Lorenz",
|
||||
"email": "thlorenz@gmx.de",
|
||||
"url": "http://thlorenz.com"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/thlorenz/deep-is/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"deprecated": false,
|
||||
"description": "node's assert.deepEqual algorithm except for NaN being equal to NaN",
|
||||
"devDependencies": {
|
||||
"tape": "~1.0.2"
|
||||
},
|
||||
"directories": {
|
||||
"lib": ".",
|
||||
"example": "example",
|
||||
"test": "test"
|
||||
},
|
||||
"homepage": "https://github.com/thlorenz/deep-is#readme",
|
||||
"keywords": [
|
||||
"equality",
|
||||
"equal",
|
||||
"compare"
|
||||
],
|
||||
"license": {
|
||||
"type": "MIT",
|
||||
"url": "https://github.com/thlorenz/deep-is/blob/master/LICENSE"
|
||||
},
|
||||
"main": "index.js",
|
||||
"name": "deep-is",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+ssh://git@github.com/thlorenz/deep-is.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "tape test/*.js"
|
||||
},
|
||||
"testling": {
|
||||
"files": "test/*.js",
|
||||
"browsers": {
|
||||
"ie": [
|
||||
6,
|
||||
7,
|
||||
8,
|
||||
9
|
||||
],
|
||||
"ff": [
|
||||
3.5,
|
||||
10,
|
||||
15
|
||||
],
|
||||
"chrome": [
|
||||
10,
|
||||
22
|
||||
],
|
||||
"safari": [
|
||||
5.1
|
||||
],
|
||||
"opera": [
|
||||
12
|
||||
]
|
||||
}
|
||||
},
|
||||
"version": "0.1.3"
|
||||
}
|
16
node_modules/deep-is/test/NaN.js
generated
vendored
Normal file
16
node_modules/deep-is/test/NaN.js
generated
vendored
Normal file
|
@ -0,0 +1,16 @@
|
|||
var test = require('tape');
|
||||
var equal = require('../');
|
||||
|
||||
test('NaN and 0 values', function (t) {
|
||||
t.ok(equal(NaN, NaN));
|
||||
t.notOk(equal(0, NaN));
|
||||
t.ok(equal(0, 0));
|
||||
t.notOk(equal(0, 1));
|
||||
t.end();
|
||||
});
|
||||
|
||||
|
||||
test('nested NaN values', function (t) {
|
||||
t.ok(equal([ NaN, 1, NaN ], [ NaN, 1, NaN ]));
|
||||
t.end();
|
||||
});
|
23
node_modules/deep-is/test/cmp.js
generated
vendored
Normal file
23
node_modules/deep-is/test/cmp.js
generated
vendored
Normal file
|
@ -0,0 +1,23 @@
|
|||
var test = require('tape');
|
||||
var equal = require('../');
|
||||
|
||||
test('equal', function (t) {
|
||||
t.ok(equal(
|
||||
{ a : [ 2, 3 ], b : [ 4 ] },
|
||||
{ a : [ 2, 3 ], b : [ 4 ] }
|
||||
));
|
||||
t.end();
|
||||
});
|
||||
|
||||
test('not equal', function (t) {
|
||||
t.notOk(equal(
|
||||
{ x : 5, y : [6] },
|
||||
{ x : 5, y : 6 }
|
||||
));
|
||||
t.end();
|
||||
});
|
||||
|
||||
test('nested nulls', function (t) {
|
||||
t.ok(equal([ null, null, null ], [ null, null, null ]));
|
||||
t.end();
|
||||
});
|
15
node_modules/deep-is/test/neg-vs-pos-0.js
generated
vendored
Normal file
15
node_modules/deep-is/test/neg-vs-pos-0.js
generated
vendored
Normal file
|
@ -0,0 +1,15 @@
|
|||
var test = require('tape');
|
||||
var equal = require('../');
|
||||
|
||||
test('0 values', function (t) {
|
||||
t.ok(equal( 0, 0), ' 0 === 0');
|
||||
t.ok(equal( 0, +0), ' 0 === +0');
|
||||
t.ok(equal(+0, +0), '+0 === +0');
|
||||
t.ok(equal(-0, -0), '-0 === -0');
|
||||
|
||||
t.notOk(equal(-0, 0), '-0 !== 0');
|
||||
t.notOk(equal(-0, +0), '-0 !== +0');
|
||||
|
||||
t.end();
|
||||
});
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue