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

Should we have Temporal-specific Date.p.toLocale*String tests? #2470

Open
justingrant opened this issue Jan 10, 2023 · 3 comments
Open

Should we have Temporal-specific Date.p.toLocale*String tests? #2470

justingrant opened this issue Jan 10, 2023 · 3 comments

Comments

@justingrant
Copy link
Collaborator

Date.p.toLocale*String should accept Temporal.Calendar and Temporal.TimeZone for calendar and timeZone options. Should we add Test262 tests for these cases?

@ljharb
Copy link
Member

ljharb commented Jan 10, 2023

It's unlikely to be implemented unless there's test262 tests for it.

@justingrant
Copy link
Collaborator Author

Because calendar and timeZone are coerced to strings by the current spec (in InitializeDateTimeFormat), there's nothing to implement. It should just work.

But any future changes to the spec could perhaps break this working behavior, so it might be helpful to have tests to verify that Temporal objects work for those options.

@ljharb
Copy link
Member

ljharb commented Jan 11, 2023

I completely agree.

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

2 participants