Skip to content

test: add roundtrip tests for pad_referential_values / unpad_referential_values#18

Open
gaomingyi779-del wants to merge 1 commit into
gialmisi:masterfrom
gaomingyi779-del:test/add-pad-unpad-roundtrip-tests
Open

test: add roundtrip tests for pad_referential_values / unpad_referential_values#18
gaomingyi779-del wants to merge 1 commit into
gialmisi:masterfrom
gaomingyi779-del:test/add-pad-unpad-roundtrip-tests

Conversation

@gaomingyi779-del

Copy link
Copy Markdown

Issue

Closes #16

Changes

Added 6 pytest tests covering:

  • Roundtrip identity with ragged lengths
  • Padding shape (n_attributes, max_len)
  • Padding tail values are np.inf; real values not
  • Uniform lengths produce no inf padding
  • Single attribute roundtrip
  • Unpad returns independent copies (mutation safety)

All 10 tests pass. No production code changes.

🤖 Generated with Claude Code

@
test: add roundtrip tests for pad_referential_values / unpad_referential_values

Adds 6 tests per issue gialmisi#16 covering:
- Roundtrip identity with ragged lengths (3 arrays of varying size)
- Padding shape assertion: (n_attributes, max_len)
- Padding tail values are np.inf; real values are not
- Uniform lengths produce no inf padding
- Single attribute roundtrip
- Unpad returns independent copies (mutation safety)

All 10 tests pass (4 pre-existing + 6 new).

Co-Authored-By: Claude <noreply@anthropic.com>
@
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.74%. Comparing base (79e7103) to head (9be0fe2).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #18      +/-   ##
==========================================
+ Coverage   78.62%   78.74%   +0.11%     
==========================================
  Files           5        5              
  Lines         861      861              
  Branches      129      129              
==========================================
+ Hits          677      678       +1     
+ Misses        143      142       -1     
  Partials       41       41              

☔ 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.

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 roundtrip tests for pad_referential_values / unpad_referential_values

2 participants