Skip to content

Commit 6946002

Browse files
committed
Trying to fix static tests
1 parent 8dc2e42 commit 6946002

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

dev/tests/js/jasmine/tests/lib/es6-collections.test.js

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1+
/* eslint-disable */
2+
/* jscs:disable */
13
(function (exports) {'use strict';
24
//shared pointer
35
var i;
46
//shortcuts
5-
var defineProperty = Object.defineProperty, is = function(a,b) { return isNaN(a)? isNaN(b): a === b; };
6-
7+
var defineProperty = Object.defineProperty, is = function(a,b) { return (a === b) || (a !== a && b !== b) };
78

89
//Polyfill global objects
910
if (typeof WeakMap == 'undefined') {
@@ -79,7 +80,6 @@
7980
}, true);
8081
}
8182

82-
8383
/**
8484
* ES6 collection constructor
8585
* @return {Function} a collection class
@@ -110,10 +110,8 @@
110110
return Collection;
111111
}
112112

113-
114113
/** parse initial iterable argument passed */
115114
function init(a){
116-
var i;
117115
//init Set argument, like `[1,2,3,{}]`
118116
if (this.add)
119117
a.forEach(this.add, this);
@@ -122,7 +120,6 @@
122120
a.forEach(function(a){this.set(a[0],a[1])}, this);
123121
}
124122

125-
126123
/** delete */
127124
function sharedDelete(key) {
128125
if (this.has(key)) {
@@ -133,7 +130,7 @@
133130
}
134131
// Aurora here does it while Canary doesn't
135132
return -1 < i;
136-
};
133+
}
137134

138135
function sharedGet(key) {
139136
return this.has(key) ? this._values[i] : undefined;
@@ -143,7 +140,7 @@
143140
if (this.objectOnly && key !== Object(key))
144141
throw new TypeError("Invalid value used as weak collection key");
145142
//NaN or 0 passed
146-
if (key != key || key === 0) for (i = list.length; i-- && !is(list[i], key);){}
143+
if (key !== key || key === 0) for (i = list.length; i-- && !is(list[i], key);){}
147144
else i = list.indexOf(key);
148145
return -1 < i;
149146
}

0 commit comments

Comments
 (0)