-
Notifications
You must be signed in to change notification settings - Fork 350
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
exposing DataServiceActionQuery<T>
properties for testing purposes
#2842
base: release-7.x
Are you sure you want to change the base?
Conversation
This PR has Quantification details
Why proper sizing of changes matters
Optimal pull request sizes drive a better predictable PR flow as they strike a
What can I do to optimize my changes
How to interpret the change counts in git diff output
Was this comment helpful? 👍 :ok_hand: :thumbsdown: (Email) |
get | ||
{ | ||
foreach (var element in this.parameters) | ||
{ | ||
yield return element; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume this is done so that the user does not modify the array. But it seems excessive to me, especially given that we do not seem modify the list internally. I think by the time they're casting it back into array to try and modify it, they're already assuming any risks that come with that. But if we really want to prevent that, then maybe it's better to hand them a ReadOnlyCollection
that's computed once so we don't have to generate the enumerable each time the property is accessed.
Issues
This pull request fixes #2841.
Description
Exposing two properties on
DataServiceActionQuery<T>
to facilitate testing