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 extra tests for the compare function in EntryComparator.java #3

Open
raeef96 opened this issue Feb 21, 2024 · 1 comment
Open
Assignees
Labels
enhancement New feature or request

Comments

@raeef96
Copy link
Collaborator

raeef96 commented Feb 21, 2024

TODO :

Write two tests that adds extra coverage to the compare function.

@raeef96 raeef96 self-assigned this Feb 21, 2024
@raeef96 raeef96 added the enhancement New feature or request label Feb 21, 2024
raeef96 added a commit that referenced this issue Feb 21, 2024
the useNextComparatorForTieBreak() checks if the next comparator is used if the primary comparator find two entities are identical
raeef96 added a commit that referenced this issue Feb 22, 2024
Added a function that reaches a branch where numerical fields are set to nun numerical and the code reaches the catch branch

Code coverage before the two tests : 75%
Code coverage after the two tests : 83%
@koppor
Copy link

koppor commented Feb 22, 2024

For reference, the class is https://github.com/JabRef/jabref/blob/main/src/main/java/org/jabref/logic/bibtex/comparator/EntryComparator.java

TBH, really challenging and helping JabRef is to continue at
src/test/java/org/jabref/logic/database/DuplicateCheckTest.java to fix JabRef#8885.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

2 participants