Skip to content

test: migrate constants/float32/ln-two-pi to ULP-based assertions - #16081

Merged
kgryte merged 1 commit into
developfrom
philipp/ulp-constants-float32-ln-two-pi
Oct 12, 2026
Merged

kgryte merged 1 commit into
developfrom
philipp/ulp-constants-float32-ln-two-pi

Conversation

@Planeshifter

Copy link
Copy Markdown
Member

Progresses #11352.

Description

What is the purpose of this pull request?

This pull request:

  • migrates the tests of constants/float32/ln-two-pi from an EPS-based tolerance check to a ULP-based assertion using @stdlib/number/float32/base/assert/is-almost-same-value.
  • uses a ULP bound of 0. The bound was tightened from 64 downward and the measured minimum was 0 (the constant exactly equals lnf( 2.0*PI )). Results were identical across two runs. This mirrors the existing constants/float32/ln-ten conversion.

Related Issues

Does this pull request have any related issues?

This pull request has the following related issues:

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

The commit was made with --no-verify because the editorconfig pre-commit hook could not download its binary in the sandbox (network 403). ESLint on the changed file is clean.

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

This PR was written by Claude Code running as an automated scheduled routine.


@stdlib-js/reviewers

🤖 Generated with Claude Code

https://claude.ai/code/session_013KapyseTChgdx2x7YJoQUt


Generated by Claude Code

@stdlib-bot

Copy link
Copy Markdown
Contributor

Coverage Report

Package Statements Branches Functions Lines
constants/float32/ln-two-pi $\\color{green}55/55$
$\\color{green}+100.00\\%$
$\\color{green}1/1$
$\\color{green}+100.00\\%$
$\\color{green}0/0$
$\\color{green}+100.00\\%$
$\\color{green}55/55$
$\\color{green}+100.00\\%$

The above coverage report was generated for the changes in this PR.

@kgryte kgryte added the Tests Pull requests specifically adding tests. label Oct 12, 2026
@kgryte
kgryte marked this pull request as ready for review October 12, 2026 13:41
@kgryte
kgryte requested a review from a team October 12, 2026 13:41
@kgryte
kgryte merged commit 07bed02 into develop Oct 12, 2026
34 checks passed
@kgryte
kgryte deleted the philipp/ulp-constants-float32-ln-two-pi branch October 12, 2026 13:42
@stdlib-bot stdlib-bot added Needs Review A pull request which needs code review. and removed Needs Review A pull request which needs code review. labels Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Tests Pull requests specifically adding tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants