Skip to content

Add unit tests for SquareRootWithBabylonianMethod#7504

Open
JulianGStudium wants to merge 2 commits into
TheAlgorithms:masterfrom
JulianGStudium:patch-1
Open

Add unit tests for SquareRootWithBabylonianMethod#7504
JulianGStudium wants to merge 2 commits into
TheAlgorithms:masterfrom
JulianGStudium:patch-1

Conversation

@JulianGStudium

Copy link
Copy Markdown
Contributor
  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized it.
  • All filenames are in PascalCase.
  • All functions and variable names follow Java naming conventions.
  • All new algorithms have a URL in their comments that points to Wikipedia or other similar explanations.
  • All new algorithms include a corresponding test class that validates their functionality.
  • All new code is formatted with clang-format -i --style=file path/to/your/file.java

#HSFDPMUW

Adds JUnit 5 unit tests for `SquareRootWithBabylonianMethod`, which previously had no test coverage. Tests cover perfect squares, non-perfect squares, and a range of values from 1 to 1000, comparing the result against Math.sqrt with a small delta.

#HSFDPMUW
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant