Skip to content

test: cover dtype converter validation guards#190

Open
wkentaro wants to merge 1 commit into
mainfrom
test/dtype-validation-coverage
Open

test: cover dtype converter validation guards#190
wkentaro wants to merge 1 commit into
mainfrom
test/dtype-validation-coverage

Conversation

@wkentaro

Copy link
Copy Markdown
Owner

bool2ubyte and float2ubyte had four input-validation guards but no
error-path tests.

Summary

  • Cover bool2ubyte rejecting a non-bool dtype.
  • Cover float2ubyte rejecting a non-float dtype, values below 0, and values
    above 1.

Test plan

  • uv run pytest tests/unit/_dtype_test.py (6 passed)
  • full suite uv run --extra all pytest -n=auto tests (251 passed)
  • uv run ruff check, ruff format --check, ty check on the changed file

@wkentaro wkentaro self-assigned this Jun 10, 2026
bool2ubyte and float2ubyte had four input-validation guards but no error-path
tests. Cover bool2ubyte rejecting a non-bool dtype, and float2ubyte rejecting a
non-float dtype, values below 0, and values above 1.
@wkentaro wkentaro marked this pull request as ready for review June 10, 2026 14:56
@wkentaro wkentaro force-pushed the test/dtype-validation-coverage branch from e201a08 to d6523ce Compare June 10, 2026 14:56
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