Skip to content

Line3: increase test coverage (backport #813) (backport #821) - #837

Merged
scpeters merged 2 commits into
gz-math8from
mergify/bp/gz-math8/pr-821
Aug 31, 2026
Merged

Line3: increase test coverage (backport #813) (backport #821)#837
scpeters merged 2 commits into
gz-math8from
mergify/bp/gz-math8/pr-821

Conversation

@mergify

@mergify mergify Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

🦟 Bug fix

Improve test coverage of the Line3 class, similar to #807

Summary

This increases test coverage based on suggestions from Gemini and uses static_cast<T> where needed to fix windows C4244 compiler warnings.

Summary of test coverage improvements

  1. Default Constructor: Tested Line3() initialization.
  2. Set Overload: Added tests for Set(const Vector3<T>&, const Vector3<T>&).
  3. Intersect Edge Cases: Added tests for parallel non-overlapping line segments, parallel overlapping segments, and non-intersecting skew lines.
  4. Template Types: Added test cases for Line3i (int) and Line3f (float).

Backport Policy

  • This is safe to backport to the following versions:
    • Jetty
    • Ionic
    • Harmonic
    • Fortress
  • This should not be backported
  • I am not sure
  • Other (fill in yourself)

Checklist

  • Signed all commits for DCO
  • Added a screen capture or video to the PR description that demonstrates the fix (as needed)
  • Added tests
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • Updated Bazel files (if adding new files). Created an issue otherwise.
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers
  • Was GenAI used to generate this PR? If so, make sure to add "Assisted-by" to your commits. (See this policy for more info.)

Assisted-by: Gemini 3.6 Flash

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by and Generated-by messages.

Backports: If this is a backport, please use Rebase and Merge instead.


This is an automatic backport of pull request #813 done by [Mergify](https://mergify.com).
This is an automatic backport of pull request #821 done by [Mergify](https://mergify.com).

1. Default Constructor: Tested Line3() initialization.
2. Added tests for Set(const Vector3<T>&, const Vector3<T>&).
3. Intersect Edge Cases: parallel non-overlapping line segments,
   parallel overlapping segments, and non-intersecting skew lines.
4. Template Types: Added test cases for Line3i (int) and Line3f (float).

Assisted-by: Gemini 3.6 Flash

(cherry picked from commit 578203f)

Signed-off-by: Steve Peters <scpeters@intrinsic.ai>
Co-authored-by: Steve Peters <scpeters@intrinsic.ai>
(cherry picked from commit 1044cd5)

# Conflicts:
#	src/python_pybind11/test/Line3_TEST.py
@mergify

mergify Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor Author

Cherry-pick of 1044cd5 has failed:

On branch mergify/bp/gz-math8/pr-821
Your branch is up to date with 'origin/gz-math8'.

You are currently cherry-picking commit 1044cd5.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   include/gz/math/Line3.hh
	modified:   src/Line3_TEST.cc

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   src/python_pybind11/test/Line3_TEST.py

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

Signed-off-by: Alejandro Hernandez Cordero <ahcorde@gmail.com>
@github-project-automation github-project-automation Bot moved this from Inbox to In review in Core development Aug 31, 2026
@scpeters
scpeters merged commit 1841356 into gz-math8 Aug 31, 2026
15 checks passed
@scpeters
scpeters deleted the mergify/bp/gz-math8/pr-821 branch August 31, 2026 14:04
@github-project-automation github-project-automation Bot moved this from In review to Done in Core development Aug 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants