()
| 175 | |
| 176 | |
| 177 | def test_curvature(): |
| 178 | |
| 179 | r = 10 |
| 180 | |
| 181 | c = circle(r) |
| 182 | w = polyline((0, 0), (1, 0), (1, 1)) |
| 183 | |
| 184 | assert c.curvatureAt(0) == approx(1 / r) |
| 185 | |
| 186 | curvatures = c.curvatures([0, 0.5]) |
| 187 | |
| 188 | assert approx(curvatures[0]) == curvatures[1] |
| 189 | |
| 190 | assert w.curvatureAt(0) == approx(w.curvatureAt(0.5)) |
| 191 | |
| 192 | |
| 193 | def test_normals(): |
nothing calls this directly
no test coverage detected