Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change ordering of spy creation to avoid overwrites #839

Merged
merged 1 commit into from
Nov 20, 2018

Conversation

drewsynan
Copy link
Contributor

Several Sinon tests were failing (direct_select, simple_select, and static) with the error [spyFunction].reset is not a function, as described in #838.

Changing the order of the spy setup call to after the calls to map.addControl(Draw); appears to fix the problem. It seems probable that the adding the control somehow overwrites the spy function, and so spying after addition avoids this situation. Failing tests run successfully after the swap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants