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

Add Rank overloads with OrderByDirection #620

Merged

Conversation

Head0nF1re
Copy link
Contributor

@Head0nF1re Head0nF1re commented Feb 6, 2024

resolves #544

Source:

  • Add Rank overloads with OrderByDirection in SuperLinq and
    SuperLinqAsync. This allows the user to choose the ordering direction
    when ranking the sequence

  • Add new public methods to PublicAPI.Unshipped.txt


Tests:

  • Add tests based on the existing tests for Rank and DenseRank operator.
  • Add a summary for some tests that didn't had one.

Docs:

  • Use a simpler language to describe how the items will be ranked.
  • Add parameter sortDirection in new methods.

- Add Rank overloads with OrderByDirection in SuperLinq and
  SuperLinqAsync. This allows the user to choose the ordering direction
  when ranking the sequence

- Add new public methods to PublicAPI.Unshipped.txt
Copy link

codecov bot commented Feb 6, 2024

Codecov Report

Attention: 10 lines in your changes are missing coverage. Please review.

Comparison is base (809a44d) 93.30% compared to head (4bf5ae5) 93.34%.
Report is 2 commits behind head on master.

Files Patch % Lines
Source/SuperLinq/ValueTupleEqualityComparer.cs 30.00% 6 Missing and 1 partial ⚠️
Source/SuperLinq/ScanRight.cs 87.50% 0 Missing and 1 partial ⚠️
Source/SuperLinq/Sequence.cs 88.88% 0 Missing and 1 partial ⚠️
Source/SuperLinq/ValueTupleComparer.cs 83.33% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #620      +/-   ##
==========================================
+ Coverage   93.30%   93.34%   +0.03%     
==========================================
  Files         242      248       +6     
  Lines        7767     7813      +46     
  Branches     1596     1604       +8     
==========================================
+ Hits         7247     7293      +46     
  Misses        329      329              
  Partials      191      191              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Head0nF1re Head0nF1re marked this pull request as ready for review February 7, 2024 04:00
@Head0nF1re
Copy link
Contributor Author

Forgot about DenseRankTests, will add those tomorrow

@Head0nF1re Head0nF1re marked this pull request as draft February 7, 2024 04:33
- Add tests for DenseRank.

- Add test for OrderByDirection.Descending.

- Add tests for Person sequence with some equal elements.
@Head0nF1re Head0nF1re marked this pull request as ready for review February 7, 2024 19:07
Copy link
Owner

@viceroypenguin viceroypenguin left a comment

Choose a reason for hiding this comment

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

couple minor fixes, and should be good to merge. thanks!

Source/SuperLinq/Rank.cs Outdated Show resolved Hide resolved
Tests/SuperLinq.Test/RankTest.cs Outdated Show resolved Hide resolved
@viceroypenguin viceroypenguin merged commit 8adb9c7 into viceroypenguin:master Feb 10, 2024
4 checks passed
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.

Add Rank/DenseRank overloads
2 participants