Skip to content

Commit

Permalink
Fix groupBy string test keys to be insertion order
Browse files Browse the repository at this point in the history
  • Loading branch information
syg authored and ptomato committed Apr 11, 2024
1 parent e11ef85 commit 3672f5d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion test/built-ins/Map/groupBy/string.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ const map = Map.groupBy(string, function (char) {
return char < 'πŸ™' ? 'before' : 'after';
});

assert.compareArray(Array.from(map.keys()), ['before', 'after']);
assert.compareArray(Array.from(map.keys()), ['after', 'before']);
assert.compareArray(map.get('before'), ['πŸ’©', '😈']);
assert.compareArray(map.get('after'), ['πŸ₯°', 'πŸ™']);
2 changes: 1 addition & 1 deletion test/built-ins/Object/groupBy/string.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ const obj = Object.groupBy(string, function (char) {
return char < 'πŸ™' ? 'before' : 'after';
});

assert.compareArray(Object.keys(obj), ['before', 'after']);
assert.compareArray(Object.keys(obj), ['after', 'before']);
assert.compareArray(obj.before, ['πŸ’©', '😈']);
assert.compareArray(obj.after, ['πŸ₯°', 'πŸ™']);

0 comments on commit 3672f5d

Please sign in to comment.