Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

bug: using null or undefined as the @Mock(() => result) throws error #138

Open
Open
bug: using null or undefined as the @Mock(() => result) throws error#138
Labels
bug Something isn't working

Description

If i use null or undefined as the @Mock(() => result), it throws:

TypeError: Cannot convert undefined or null to object
at Function.getOwnPropertyNames ()

at getClassMembers (../../../node_modules/@plumier/reflect/lib/parser.js:87:28)
at parseMethods (../../../node_modules/@plumier/reflect/lib/parser.js:134:21)
at parseClassNoCache (../../../node_modules/@plumier/reflect/lib/parser.js:173:18)
at ../../../node_modules/@plumier/reflect/lib/helpers.js:18:31
at walkTypeMembers (../../../node_modules/@plumier/reflect/lib/walker.js:35:45)
at walkTypeMembersRecursive (../../../node_modules/@plumier/reflect/lib/walker.js:54:23)
at reflectClass (../../../node_modules/@plumier/reflect/lib/reflect.js:15:55)
at reflectModuleOrClass (../../../node_modules/@plumier/reflect/lib/reflect.js:66:16)
at ../../../node_modules/@plumier/reflect/lib/helpers.js:18:31

Originally posted by @arthurfiorette in #135 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug Something isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions