mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
LibJS: Add more test matchers
This commit is contained in:
parent
5e971c91e3
commit
fc08222f46
Notes:
sideshowbarker
2024-07-19 05:04:52 +09:00
Author: https://github.com/mattco98
Commit: fc08222f46
Pull-request: https://github.com/SerenityOS/serenity/pull/2689
Reviewed-by: https://github.com/linusg
8 changed files with 200 additions and 46 deletions
|
@ -1,8 +1,8 @@
|
|||
describe("[[IsExtensible]] trap normal behavior", () => {
|
||||
test("forwarding when not defined in handler", () => {
|
||||
expect(Object.isExtensible(new Proxy({}, { isExtensible: null }))).toBe(true);
|
||||
expect(Object.isExtensible(new Proxy({}, { isExtensible: undefined }))).toBe(true);
|
||||
expect(Object.isExtensible(new Proxy({}, {}))).toBe(true);
|
||||
expect(Object.isExtensible(new Proxy({}, { isExtensible: null }))).toBeTrue();
|
||||
expect(Object.isExtensible(new Proxy({}, { isExtensible: undefined }))).toBeTrue();
|
||||
expect(Object.isExtensible(new Proxy({}, {}))).toBeTrue();
|
||||
});
|
||||
|
||||
test("correct arguments supplied to trap", () => {
|
||||
|
@ -14,7 +14,7 @@ describe("[[IsExtensible]] trap normal behavior", () => {
|
|||
}
|
||||
});
|
||||
|
||||
expect(Object.isExtensible(p)).toBe(true);
|
||||
expect(Object.isExtensible(p)).toBeTrue();
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue