Repository navigation
Merged
Conversation
Add test cases for trying to convert valid and invalid GUID values. Catch exception in TryConvertTo Catch when the converter throws an exception and return false and set the out value to default. Change to Guid specific Converter Remove try/catch added in TryConvertTo and replace with Guid Converter Add case for Nullable Guid Add tests for NullableGuid Fix NullableGuid parse reflect a null as parsed
pranavkm
approved these changes
Jan 20, 2022
| { | ||
| parser = ConvertToGuid; | ||
| } | ||
| else if (typeof(T) == typeof(Guid?)) |
Contributor
There was a problem hiding this comment.
Kinda unrelated - I imagine this block of code would look a lot nicer as a switch expression.
Member
Author
There was a problem hiding this comment.
Yes, probably. This code predates switch expressions. Keeping this out-of-scope for the PR though.
|
Hello @SteveSandersonMS! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
ghost
deleted the
pr/33594
branch
January 21, 2022 15:41
ShreyasJejurkar
pushed a commit
to ShreyasJejurkar/aspnetcore
that referenced
this pull request
Jan 22, 2022
* Add test for TryConvertTo for GUID type Add test cases for trying to convert valid and invalid GUID values. Catch exception in TryConvertTo Catch when the converter throws an exception and return false and set the out value to default. Change to Guid specific Converter Remove try/catch added in TryConvertTo and replace with Guid Converter Add case for Nullable Guid Add tests for NullableGuid Fix NullableGuid parse reflect a null as parsed * Update src/Components/Components/test/BindConverterTest.cs Co-authored-by: Jeff Layton <jeffl8n@users.noreply.github.com>
This pull request was closed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a continuation of #33594. I had to create a new PR because the original one was no longer mergeable and further tweaks were needed.