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

Extends specs of Exception#detailed_message #1170

Merged
merged 2 commits into from
Jun 27, 2024

Conversation

herwinw
Copy link
Member

@herwinw herwinw commented Jun 27, 2024

There are a few additional cases for empty messages

There is a specific path for instances of RuntimeError, the other path
(returning the name of the class) is used for every other instance, not
just for subclasses of RuntimeError.
There is a specific code path for exceptions with an empty message. Test
both the RuntimeError and another exception class.
Move the existing code a bit, to keep the ordering/grouping of specs a
bit more logical.
@andrykonchin
Copy link
Member

andrykonchin commented Jun 27, 2024

Thank you!

The logic related to highlighting seems not covered well enough.

@andrykonchin andrykonchin merged commit 3d4f1e5 into ruby:master Jun 27, 2024
14 checks passed
@herwinw herwinw deleted the exception_detailed_message branch June 27, 2024 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants