-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Blob constructor 'endings' options #8456
Blob constructor 'endings' options #8456
Conversation
Note that we shouldn't merge this until:
|
Build PASSEDStarted: 2017-11-29 20:28:13 View more information about this build on: |
Needs cases for newlines split across strings, i.e. |
(FWIW, looks great thus far.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed with @annevk that we of course need the spec text and File constructor tests as well. I'll have a go at spec text tomorrow, if nobody else beats me to it.
JSON.stringify(value)); | ||
}); | ||
|
||
const test_error = {name: 'test', message: 'test error'}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having anything other than a name in here is a bit pointless, as assert_throws only checks the name anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. (copied from Blob-constructor.html, but leaving it alone there)
} | ||
|
||
test(function() { | ||
[ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I slightly prefer if each of these cases was their own test, rather than having them be assertions in one combined test, but this is fine too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
Spec in w3c/FileAPI#90 |
Done.
Done. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I guess all browsers pass these? Or do w need to file a bug against Edge perhaps?
What's going on with the edge results for these anyway, somehow none of the tests are getting run and instead a "top-level" failure of "Expected ')'" is reported? |
Well, I'm guessing that is a problem with the WPT infra, running these locally in edge seems to work fine (and shows that edge indeed completely ignores the endings attribute). |
Thanks for reviewing/merging! Also thanks for trying out in Edge — I hadn't run these in any other browser yet. As noted in w3c/FileAPI#46 Edge should parse the attribute but ignore it. @aliams - do you need a bug or do you have one already? |
Tests for the 'endings' options for the Blob and File constructor.
w3c/FileAPI#46