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

provide untyped comparison for ByteSize #294

Merged
merged 3 commits into from
Jun 12, 2014

Conversation

mexx
Copy link
Collaborator

@mexx mexx commented Jun 11, 2014

fixes #292

[InlineData(13, 23, -1)]
[InlineData(23, 23, 0)]
[InlineData(45, 23, 1)]
public void CompareUntyped(double value, double valueToCompareWith, int expectedResult)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the unit tests. I'd also like to see tests for sorting here; e.g. 1GB, 3KB and 5MB should sort to 3KB, 5MB and 1GB.

@MehdiK
Copy link
Member

MehdiK commented Jun 11, 2014

Thanks. I didn't realize it was already implementing IComparable<>. This is small and clean and I am happy for it to be merged. Please just add the sorting test.

@mexx
Copy link
Collaborator Author

mexx commented Jun 12, 2014

Added sorting tests. I'm glad to help when I can :)

MehdiK added a commit that referenced this pull request Jun 12, 2014
provide untyped comparison for ByteSize
@MehdiK MehdiK merged commit d91fcd7 into Humanizr:master Jun 12, 2014
@MehdiK
Copy link
Member

MehdiK commented Jun 22, 2014

This is now released to NuGet as v1.27.0. Thanks for your contribution.

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

Successfully merging this pull request may close these issues.

ByteSize should implement IComparable
2 participants