You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/Users/arlanjaska/sandbox/sinon_testing/node_modules/type-detect/type-detect.js:45
function typeDetect(obj) {
^
RangeError: Maximum call stack size exceeded
at typeDetect (/Users/arlanjaska/sandbox/sinon_testing/node_modules/type-detect/type-detect.js:45:20)
at typeOf (/Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/commons/lib/type-of.js:12:12)
at /Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/samsam/lib/create-matcher/match-object.js:46:20
at Array.every (<anonymous>)
at matchObject (/Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/samsam/lib/create-matcher/match-object.js:38:12)
at /Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/samsam/lib/create-matcher/match-object.js:47:18
at Array.every (<anonymous>)
at matchObject (/Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/samsam/lib/create-matcher/match-object.js:38:12)
at /Users/arlanjaska/sandbox/sinon_testing/node_modules/@sinonjs/samsam/lib/create-matcher/match-object.js:47:18
at Array.every (<anonymous>)
Additional context
This could probably be solved for this case by tossing in an identical() check somewhere in here. Not sure how it's handled in general though.
When using sinon.match with an object literal (for partial matching), samsam enters an infinite loop.
What did you expect to happen?
Sinon correctly supports circular objects without sinon.match, so I expected this to work. (See workarounds below).
What actually happens
RangeError: Maximum call stack size exceeded
How to reproduce
Output
Additional context
This could probably be solved for this case by tossing in an
identical()
check somewhere in here. Not sure how it's handled in general though.Workarounds
The text was updated successfully, but these errors were encountered: