Skip to content

Test improvements - #666

Merged
TwoLettuce merged 2 commits into
mainfrom
test-improvements
Jul 31, 2026
Merged

Test improvements#666
TwoLettuce merged 2 commits into
mainfrom
test-improvements

Conversation

@TwoLettuce

Copy link
Copy Markdown
Contributor

Overview

Modified the SQL/Memory DAO implementations of getBestSubmissionForPhase() to retreive the best submission by score AND by date, rather than just by score.

This change enabled the SubmissionDaoTest.getBestSubmissionWithDuplicateScore test to work properly, so it has been re-enabled.

I figure I might as well submit this PR now, because having the oldest submission with the highest score will be relevant for #664

Details

  • SubmissionSqlDao now sorts by score DESC and timestamp ASC
  • SubmissionsMemoryDao now checks timestamps when iterating through submissions.

Testing

  • Added/updated unit tests
  • Tested edge cases
  • Manual testing (if needed)

@ZakkeryDaRebel ZakkeryDaRebel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me, and I have all the tests passing on my machine

@TwoLettuce
TwoLettuce merged commit e02628d into main Jul 31, 2026
3 checks passed
@TwoLettuce
TwoLettuce deleted the test-improvements branch July 31, 2026 16:18
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.

3 participants