Test that small slopes are not coerced to zero in the transform.
()
| 402 | |
| 403 | |
| 404 | def test_axline_small_slope(): |
| 405 | """Test that small slopes are not coerced to zero in the transform.""" |
| 406 | line = plt.axline((0, 0), slope=1e-14) |
| 407 | p1 = line.get_transform().transform_point((0, 0)) |
| 408 | p2 = line.get_transform().transform_point((1, 1)) |
| 409 | # y-values must be slightly different |
| 410 | dy = p2[1] - p1[1] |
| 411 | assert dy > 0 |
| 412 | assert dy < 4e-12 |
nothing calls this directly
no test coverage detected
searching dependent graphs…