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

Ensure exceptions thrown by components during async renders are propagated to test thread #319

Closed
egil opened this issue Feb 6, 2021 · 1 comment · Fixed by #344
Closed
Assignees
Labels
bug Something isn't working enhancement New feature or request
Milestone

Comments

@egil
Copy link
Member

egil commented Feb 6, 2021

When a component re-renders asynchronously, any exceptions thrown should be propagated to the test thread. The related question, #318, shows a case where this did not happen, making it hard to diagnose the issue with the test.

@egil egil added bug Something isn't working enhancement New feature or request labels Feb 6, 2021
@egil egil self-assigned this Mar 18, 2021
@egil
Copy link
Member Author

egil commented Mar 18, 2021

After trying out a few ways to achieve this, the best option I've come across is to have the WaitFor* methods throw the any unhandled exceptions caught by the renderer. This will allow users who have async code to capture the exceptions. Sync code will simply surface the exception normally, so I think this is a pretty decent solution.

@egil egil added this to the v1.0.0 milestone Mar 18, 2021
@egil egil linked a pull request Mar 22, 2021 that will close this issue
9 tasks
@egil egil closed this as completed Mar 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant