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

fixes Location#compareTo(Location) #3519

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

BookWood7th
Copy link
Contributor

@BookWood7th BookWood7th commented Oct 21, 2024

Related Issue

This pull request addresses #3518.

Intended Change

Adds explicit nullsLast comparators using the natural order of URI and Position when comparing locations.
This avoids a NullPointerException, when fileUri field is null in one of the locations being compared

Type of pull request

  • Bug fix (non-breaking change which fixes an issue)
  • Refactoring (behaviour should not change or only minimally change)
  • There are changes to the (Java) code

Ensuring quality

  • I made sure that introduced/changed code is well documented (javadoc and inline comments).
  • I have tested the feature as follows: KeY test suite

Additional information and contact(s)

The contributions within this pull request are licensed under GPLv2 (only) for inclusion in KeY.

Copy link

codecov bot commented Oct 21, 2024

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.

Project coverage is 38.17%. Comparing base (4121ecc) to head (3ebff5e).
Report is 17 commits behind head on main.

Files with missing lines Patch % Lines
...src/main/java/de/uka/ilkd/key/parser/Location.java 0.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #3519      +/-   ##
============================================
- Coverage     38.17%   38.17%   -0.01%     
+ Complexity    17227    17226       -1     
============================================
  Files          2109     2109              
  Lines        127624   127630       +6     
  Branches      21461    21461              
============================================
- Hits          48724    48723       -1     
- Misses        72909    72917       +8     
+ Partials       5991     5990       -1     

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

@BookWood7th
Copy link
Contributor Author

BookWood7th commented Oct 21, 2024

There appears to be a test that fails unexpectedly sometimes
de.uka.ilkd.key.rule.merge.MergeRuleTests#testLoadClosedGcdProofWithMergePointStatements().
I believe @WolframPfeifer and I witnessed this test failing before when conducting windows unit tests on #3514, then not failing when running them again.

@BookWood7th BookWood7th changed the title fixes #3518 fixes Location#compareTo(Location) Oct 23, 2024
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.

1 participant