Skip to content

Re-enable GenomeFeatureBuilderTest and fix LDKNNi imputation test - #53

Merged
btmonier merged 2 commits into
developfrom
fix/issues-28-29
Oct 23, 2026
Merged

btmonier merged 2 commits into
developfrom
fix/issues-28-29

Conversation

@btmonier

Copy link
Copy Markdown
Member

Description

This PR fixes and re-enables two test classes (GenomeFeatureBuilderTest and LDKNNiImputationPluginTest) that were excluded from the main test task.

For GenomeFeatureBuilderTest (#28), testMissingFields expected build() to throw an exception when type, chromosome, start, or stop were missing. However, GenomeFeatureBuilder only requires id and treats all other fields as optional. The test now checks that missing id throws an exception and that the other fields are optional and default to "NA".

For LDKNNiImputationPluginTest (#29), there were two issues:

  1. LDKNNiImputationPlugin.getHighLDMap wrote to a non-thread-safe ArrayListMultimap from a parallel stream, causing small random differences between runs. Each parallel task now writes to its own slot in an array, and the map is built afterward on a single thread.
  2. In 2016 (TAS-1012), the default LD search distance in LDKNNiImputationPlugin changed from unlimited (-1) to 10 Mb, which raised the error rate in the test above its 3.5% limit. Setting .maxDistance(-1) in the test restores the original behavior it was written for, and raising the RIL error rate check from 5e-4 to 6e-4 accounts for the deterministic 5.09e-4 error rate.

Closes #28, closes #29.

Type of change

What type of changes does your code introduce? Put an x in boxes that apply.

  • CHANGE (fix or feature that would cause existing functionality to not work as expected)
  • FEATURE (non-breaking change which adds functionality)
  • BUGFIX (non-breaking change which fixes an issue)
  • ENHANCEMENT (non-breaking change which improves existing functionality)
  • NONE (if none of the other choices apply. Example, tooling, build system, CI, docs, etc.)

Checklist:

  • The base branch of this PR is develop (use the hotfix template if this targets main)
  • I have updated the version variable in build.gradle.kts
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated relevant documentation

@btmonier btmonier changed the title Re-enable GenomeFeatureBuilderTest and fix LDKNNi imputation test (#28, #29) Re-enable GenomeFeatureBuilderTest and fix LDKNNi imputation test Oct 21, 2026
@btmonier btmonier self-assigned this Oct 21, 2026
@codecov-commenter

codecov-commenter commented Oct 21, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 25.86%. Comparing base (2b1f8cb) to head (3562aad).

Additional details and impacted files
@@              Coverage Diff              @@
##             develop      #53      +/-   ##
=============================================
+ Coverage      25.39%   25.86%   +0.47%     
- Complexity      4918     5042     +124     
=============================================
  Files            610      610              
  Lines          73053    73056       +3     
  Branches       12590    12591       +1     
=============================================
+ Hits           18550    18896     +346     
+ Misses         52626    52272     -354     
- Partials        1877     1888      +11     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@btmonier
btmonier merged commit 55198f7 into develop Oct 23, 2026
8 checks passed
@btmonier
btmonier deleted the fix/issues-28-29 branch October 23, 2026 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

5 participants