mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-20 08:18:55 +00:00
LibJS: Implement Set.prototype.isSupersetOf
This commit is contained in:
parent
e29be4eaa8
commit
3470f33a0f
Notes:
sideshowbarker
2024-07-17 03:48:11 +09:00
Author: https://github.com/IdanHo
Commit: 3470f33a0f
Pull-request: https://github.com/SerenityOS/serenity/pull/16279
Reviewed-by: https://github.com/TobyAsE
Reviewed-by: https://github.com/davidot ✅
Reviewed-by: https://github.com/linusg ✅
4 changed files with 55 additions and 0 deletions
|
@ -0,0 +1,8 @@
|
|||
test("basic functionality", () => {
|
||||
expect(Set.prototype.isSupersetOf).toHaveLength(1);
|
||||
|
||||
const set1 = new Set(["a", "b", "c"]);
|
||||
const set2 = new Set(["b", "c"]);
|
||||
expect(set1.isSupersetOf(set2)).toBeTrue();
|
||||
expect(set2.isSupersetOf(set1)).toBeFalse();
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue