Skip to content

Force use_strict during testing#577

Merged
ziluvatar merged 2 commits intoauth0:masterfrom
enumatech:use_strict
Feb 20, 2019
Merged

Force use_strict during testing#577
ziluvatar merged 2 commits intoauth0:masterfrom
enumatech:use_strict

Conversation

@lionello
Copy link
Copy Markdown
Contributor

Our project was using JS strict mode and we got errors like

TypeError: Cannot create property 'iat' on string

Enabling --use_strict during the mocha test revealed the culprit.

@ziluvatar
Copy link
Copy Markdown
Contributor

ziluvatar commented Feb 18, 2019

Could you add some tests on claim-iat.test.js file to assert that behavior is not changing for string payloads (proper stringified json and just a plain string like in your issue)

@lionello
Copy link
Copy Markdown
Contributor Author

@ziluvatar Done. Please check if it's what you had in mind.

@ziluvatar ziluvatar merged commit 7b60c12 into auth0:master Feb 20, 2019
@ziluvatar
Copy link
Copy Markdown
Contributor

Thanks @lionello 👏

@lionello lionello deleted the use_strict branch February 20, 2019 12:38
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