-
Notifications
You must be signed in to change notification settings - Fork 7
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
Add blob support to _assertDeepEqual
#11
Conversation
- Also, what it `type`?
- Switch back to the use of `type()` in the first `switch` to reduce impact on existing code - `type(blob())` returns "meta", so added code to specifically catch "meta", and then perform `typeof`. If the result of `typeof` is "blob", then we handle the same as the case of "table"/"class"/"array", but otherwise we handle it as the default case
It is recommended to compare blobs by the one imp API method - crypto.equals() that would make the code much simpler. Or do you need to print out the details of the comparison, like the "index" of the first non-equal byte, etc? |
I don't think printing out the first non-equal byte is necessary, so yes this could be updated to use |
Updated to use |
If you manually tested it, it's ready. |
:) will let you know soon |
oh... seems, it would be also good to add a check that value2 is a blob as well. |
I thought that was already in there, good catch! |
Add blob support for PR #10