Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: Display differences #2862

Merged
merged 2 commits into from
Dec 9, 2017
Merged

Conversation

wiredfool
Copy link
Member

I've been thinking about something like this since we had the issue that was non-reproducable on any of my machines.

What this does is push all test failures for assert_image_equal and assert_image_similar to a webservice, where it displays those images and the difference.

======================================================================

FAIL: TestUploader.test_upload_equal

----------------------------------------------------------------------

Traceback (most recent call last):

  File "/home/travis/build/wiredfool/Pillow/Tests/test_uploader.py", line 10, in test_upload_equal

    self.assert_image_equal(result, target)

  File "/home/travis/build/wiredfool/Pillow/Tests/helper.py", line 104, in assert_image_equal

    self.fail(msg or "got different content")

AssertionError: got different content

-------------------- >> begin captured logging << --------------------

urllib3.connectionpool: DEBUG: Starting new HTTPS connection (1): fmuvehxed0.execute-api.us-east-2.amazonaws.com

urllib3.connectionpool: DEBUG: https://fmuvehxed0.execute-api.us-east-2.amazonaws.com:443 "GET /prod/upload HTTP/1.1" 200 3421

urllib3.connectionpool: DEBUG: Starting new HTTPS connection (1): s3.us-east-2.amazonaws.com

urllib3.connectionpool: DEBUG: https://s3.us-east-2.amazonaws.com:443 "POST /pillow-test-image-results HTTP/1.1" 204 0

urllib3.connectionpool: DEBUG: Starting new HTTPS connection (1): s3.us-east-2.amazonaws.com

urllib3.connectionpool: DEBUG: https://s3.us-east-2.amazonaws.com:443 "POST /pillow-test-image-results HTTP/1.1" 204 0

helper: ERROR: Url for test images: https://fmuvehxed0.execute-api.us-east-2.amazonaws.com/prod/show/1510948233.21/

--------------------- >> end captured logging << ---------------------

I'm not 100% on the output yet, and we're still not going to trigger on some forms of errors.

Comments?

@hugovk
Copy link
Member

hugovk commented Nov 17, 2017

Sounds like a good idea.

@wiredfool wiredfool merged commit dcb8d6f into python-pillow:master Dec 9, 2017
@wiredfool wiredfool deleted the difference-upload branch January 8, 2018 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants