summaryrefslogtreecommitdiff
path: root/spec/javascripts/extensions/array_spec.js
diff options
context:
space:
mode:
Diffstat (limited to 'spec/javascripts/extensions/array_spec.js')
-rw-r--r--spec/javascripts/extensions/array_spec.js23
1 files changed, 0 insertions, 23 deletions
diff --git a/spec/javascripts/extensions/array_spec.js b/spec/javascripts/extensions/array_spec.js
index 60f6b9b78e3..4b871fe967d 100644
--- a/spec/javascripts/extensions/array_spec.js
+++ b/spec/javascripts/extensions/array_spec.js
@@ -18,28 +18,5 @@ require('~/extensions/array');
return expect(arr.last()).toBe(5);
});
});
-
- describe('find', function () {
- beforeEach(() => {
- this.arr = [0, 1, 2, 3, 4, 5];
- });
-
- it('returns the item that first passes the predicate function', () => {
- expect(this.arr.find(item => item === 2)).toBe(2);
- });
-
- it('returns undefined if no items pass the predicate function', () => {
- expect(this.arr.find(item => item === 6)).not.toBeDefined();
- });
-
- it('error when called on undefined or null', () => {
- expect(Array.prototype.find.bind(undefined, item => item === 1)).toThrow();
- expect(Array.prototype.find.bind(null, item => item === 1)).toThrow();
- });
-
- it('error when predicate is not a function', () => {
- expect(Array.prototype.find.bind(this.arr, 1)).toThrow();
- });
- });
});
}).call(window);