MCPcopy Index your code
hub / github.com/python-pillow/Pillow / test_transform

Function test_transform

Tests/test_imagepath.py:168–183  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

166
167
168def test_transform() -> None:
169 # Arrange
170 p = ImagePath.Path([0, 1, 2, 3])
171 theta = math.pi / 15
172
173 # Act
174 # Affine transform, in-place
175 p.transform(
176 (math.cos(theta), math.sin(theta), 20, -math.sin(theta), math.cos(theta), 20),
177 )
178
179 # Assert
180 assert p.tolist() == [
181 (20.20791169081776, 20.978147600733806),
182 (22.58003027392089, 22.518619420565898),
183 ]
184
185
186def test_transform_with_wrap() -> None:

Callers

nothing calls this directly

Calls 1

transformMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…