From 737d20ea1572ce72eb4ce60643bb515ea95612ca Mon Sep 17 00:00:00 2001 From: Michael Heasell Date: Thu, 21 Feb 2019 21:18:46 +0000 Subject: [PATCH] Rework icepick tests to not require underscore --- types/icepick/icepick-tests.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/types/icepick/icepick-tests.ts b/types/icepick/icepick-tests.ts index 5458509d42..f1d536e78f 100644 --- a/types/icepick/icepick-tests.ts +++ b/types/icepick/icepick-tests.ts @@ -1,5 +1,4 @@ import i = require("icepick"); -import * as _ from 'underscore'; "use strict"; // so attempted modifications of frozen objects will throw errors @@ -146,15 +145,13 @@ class Foo {} { i.map(function(v) { return v * 2 }, [1, 2, 3]); // [2, 4, 6] - var removeEvens = _.partial(i.filter, function(v: number) { return v % 2; }); - - removeEvens([1, 2, 3]); // [1, 3] + i.filter(function(v: number) { return v % 2 === 0; }, [1, 2, 3]); // [1, 3] } { var arr = i.freeze([{ a: 1 }, { b: 2 }]); //ECMAScript 2015 - //arr.find(function(item) { return item.b != null; }); // {b: 2} + //arr.find(function(item) { return item.b != null; }); // {b: 2} } // chain(coll) - not defined