Add test for #183
This commit is contained in:
parent
7d468191f4
commit
9265e9072d
1 changed files with 5 additions and 0 deletions
|
|
@ -24,6 +24,8 @@ const {window} = new JSDOM();
|
||||||
const {document} = window;
|
const {document} = window;
|
||||||
const createDomElement = (element: string) => document.createElement(element);
|
const createDomElement = (element: string) => document.createElement(element);
|
||||||
|
|
||||||
|
const structuredClone = globalThis.structuredClone ?? (x => x);
|
||||||
|
|
||||||
type Test = {
|
type Test = {
|
||||||
assert: (...args: any[]) => void | never;
|
assert: (...args: any[]) => void | never;
|
||||||
fixtures: unknown[];
|
fixtures: unknown[];
|
||||||
|
|
@ -487,6 +489,9 @@ const types = new Map<string, Test>([
|
||||||
{x: 1},
|
{x: 1},
|
||||||
Object.create(null),
|
Object.create(null),
|
||||||
new Object(), // eslint-disable-line no-new-object
|
new Object(), // eslint-disable-line no-new-object
|
||||||
|
structuredClone({x: 1}),
|
||||||
|
structuredClone(Object.create(null)),
|
||||||
|
structuredClone(new Object()), // eslint-disable-line no-new-object
|
||||||
],
|
],
|
||||||
typename: 'Object',
|
typename: 'Object',
|
||||||
typeDescription: AssertionTypeDescription.plainObject,
|
typeDescription: AssertionTypeDescription.plainObject,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue