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

Host-specific hook for HostPromiseRejectionTracker #29

Open
rwaldron opened this issue Jul 27, 2017 · 8 comments
Open

Host-specific hook for HostPromiseRejectionTracker #29

rwaldron opened this issue Jul 27, 2017 · 8 comments

Comments

@rwaldron
Copy link
Contributor

The conversation begins here: tc39/test262#1156 (comment)

cc @ljharb @littledan @benjamingr @leobalter @jugglinmike

@benjamingr
Copy link

I'd love it if @domenic weighed in here too since (I think) he knows the most about HostPromiseRejectionTracker. I would love to help with anything Node related or with general test cases.

@domenic
Copy link
Member

domenic commented Jul 28, 2017

I don't think this can usefully be tested in test262, because the host's implementation could be to do nothing, in a which case no tests are applicable. Similarly, it could be arbitrarily complicated, so some kind of generic framework doesn't make sense either.

Besides the above, Node and web-platform-tests already have extensive tests of their APIs here, and so I don't think it's a high priority for test262.

@benjamingr
Copy link

@domenic so you're saying this should be tested in Node and web-platform-tests? That makes sense.

Is there a formal (or not formal) process in the web-platform tests for ECMAScript removing/adding a feature? I'm not aware of anything of the sort for Node.

@littledan
Copy link
Member

@domenic The reason this came up is because I was suggesting testing how Promise.prototype.finally interacts with this hook (since it does so in a slightly counterintuitive way). Do you think tests for these new JS language feature interactions should always be done in those embedder repositories?

@domenic
Copy link
Member

domenic commented Aug 1, 2017

Yes; everything related to host hooks should be tested in host test suites.

@ljharb
Copy link
Member

ljharb commented Aug 1, 2017

@littledan i'm not sure how it's counterintuitive - in const y = x.finally(), x is "handled" by .finally which provides a catch handler, and y is unhandled if rejected just like x was prior to that line.

I agree that host hooks should probably be tested in host tests, since there's no way to test them in the language semantics.

@littledan
Copy link
Member

@domenic So should we not have detached TypedArray tests in test262?

@domenic
Copy link
Member

domenic commented Aug 1, 2017

Detached typed arrays are not specified in terms of an arbitrary-behavior host hook.

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

No branches or pull requests

5 participants