Skip to content

Parametrize tests#2

Merged
hayatoikoma merged 3 commits intohayatoikoma:fixresamplefrom
radarhere:fixresample
Mar 28, 2026
Merged

Parametrize tests#2
hayatoikoma merged 3 commits intohayatoikoma:fixresamplefrom
radarhere:fixresample

Conversation

@radarhere
Copy link
Copy Markdown

Suggestion for python-pillow#9480

  • Combines the two tests using parametrization
  • Use paste() rather than loops and putpixel()

Copy link
Copy Markdown
Owner

@hayatoikoma hayatoikoma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the refactoring! Looks great! Just made a minor comment.

50, # # Left half = 0, right half = 65535
),
)
def test_resampling_clamp_overflow(self, x: int) -> None:
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same variable name x is used for two different things. I think it'd be nice to rename it to something else?

@hayatoikoma hayatoikoma merged commit b78e3b8 into hayatoikoma:fixresample Mar 28, 2026
47 checks passed
@radarhere radarhere deleted the fixresample branch March 28, 2026 06:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants