import { inspect } from 'node:util'; test('toBeProxy', () => { expect({}).not.toBeProxy(); expect(null).not.toBeProxy(); expect(undefined).not.toBeProxy(); expect(() => { // func }).not.toBeProxy(); expect(1).not.toBeProxy(); expect(true).not.toBeProxy(); expect(Symbol()).not.toBeProxy(); expect('Proxy [{}, {}]').not.toBeProxy(); expect({ toString() { return 'Proxy [{}, {}]'; }, }).not.toBeProxy(); expect({ [inspect.custom]() { return 'Proxy [{}, {}]'; }, }).not.toBeProxy(); expect(new Proxy({}, {})).toBeProxy(); expect( new Proxy( { [inspect.custom]() { return '{}'; }, }, {}, ), ).toBeProxy(); expect( new Proxy(() => { // func }, {}), ).toBeProxy(); });