Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 5c4c9c0

Browse filesBrowse files
committed
Merge branch 'master' of github.com:facebook/immutable-js
2 parents c203ddb + e6363b1 commit 5c4c9c0
Copy full SHA for 5c4c9c0

File tree

1 file changed

+8
-0
lines changed
Filter options

1 file changed

+8
-0
lines changed

‎__tests__/List.ts

Copy file name to clipboardExpand all lines: __tests__/List.ts
+8Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,14 @@ describe('List', () => {
8080
expect(v.get(0)).toBe('value');
8181
});
8282

83+
it('returns undefined when getting a null value', () => {
84+
var v = Immutable.List([1, 2, 3]);
85+
expect(v.get(null)).toBe(undefined);
86+
87+
var o = Immutable.List([{ a: 1 },{ b: 2 }, { c: 3 }]);
88+
expect(o.get(null)).toBe(undefined);
89+
});
90+
8391
it('counts from the end of the list on negative index', () => {
8492
var i = Immutable.List.of(1, 2, 3, 4, 5, 6, 7);
8593
expect(i.get(-1)).toBe(7);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.