Skip to content

Increase test coverage in dpnp.nextafter for signed zeros#2955

Merged
antonwolfy merged 2 commits into
masterfrom
add-test-to-nextafter
Jun 18, 2026
Merged

Increase test coverage in dpnp.nextafter for signed zeros#2955
antonwolfy merged 2 commits into
masterfrom
add-test-to-nextafter

Conversation

@antonwolfy

@antonwolfy antonwolfy commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

This PR adds a test verifying that dpnp.nextafter returns the correctly signed zero when stepping between +0.0 and -0.0.

It mirrors the regression test added with NumPy 2.5, which fixed nextafter returning the wrong-signed zero for the equal-zero case where the destination's sign must determine the sign of the resulting zero.

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • Have you checked performance impact of proposed changes?
  • Have you added documentation for your changes, if necessary?
  • Have you added your changes to the changelog?

@antonwolfy antonwolfy added this to the 0.21.0 release milestone Jun 18, 2026
@antonwolfy antonwolfy self-assigned this Jun 18, 2026
@github-actions

github-actions Bot commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

View rendered docs @ https://intelpython.github.io/dpnp/index.html

@coveralls

coveralls commented Jun 18, 2026

Copy link
Copy Markdown
Collaborator

Coverage Status

coverage: 78.092%. remained the same — add-test-to-nextafter into master

@github-actions

github-actions Bot commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Array API standard conformance tests for dpnp=0.21.0dev1=py313h509198e_11 ran successfully.
Passed: 1356
Failed: 4
Skipped: 16

@antonwolfy antonwolfy marked this pull request as ready for review June 18, 2026 12:31

@vlad-perevezentsev vlad-perevezentsev 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.

LGTM
Thank you @antonwolfy

@antonwolfy antonwolfy merged commit 188c1ce into master Jun 18, 2026
61 of 82 checks passed
@antonwolfy antonwolfy deleted the add-test-to-nextafter branch June 18, 2026 15:21
github-actions Bot added a commit that referenced this pull request Jun 18, 2026
This PR adds a test verifying that `dpnp.nextafter` returns the
correctly signed zero when stepping between `+0.0` and `-0.0`.

It mirrors the regression test added with NumPy 2.5, which fixed
`nextafter` returning the wrong-signed zero for the equal-zero case
where the destination's sign must determine the sign of the resulting
zero. 188c1ce
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