(box_and_vertex, param0, param1)
| 2047 | @pytest.mark.parametrize("param1", [-1, 0, 2]) |
| 2048 | @pytest.mark.parametrize("param0", [-2, 0, 0.01]) |
| 2049 | def test_PointInPlane_param(box_and_vertex, param0, param1): |
| 2050 | |
| 2051 | box_and_vertex.constrain("vertex", "box@faces@>Z", "PointInPlane", param=param0) |
| 2052 | box_and_vertex.constrain("vertex", "box@faces@>X", "PointInPlane", param=param1) |
| 2053 | box_and_vertex.solve() |
| 2054 | solve_result_check(box_and_vertex._solve_result) |
| 2055 | |
| 2056 | vertex_translation_part = ( |
| 2057 | box_and_vertex.children[0].loc.wrapped.Transformation().TranslationPart() |
| 2058 | ) |
| 2059 | assert vertex_translation_part.Z() - 1.5 == pytest.approx(param0, abs=1e-6) |
| 2060 | assert vertex_translation_part.X() - 0.5 == pytest.approx(param1, abs=1e-6) |
| 2061 | |
| 2062 | |
| 2063 | def test_constraint_getPln(): |
nothing calls this directly
no test coverage detected