Skip to content

Commit

Permalink
Merge pull request #32 from plone/more-flexible-icon-test
Browse files Browse the repository at this point in the history
More flexible test of getIcon.
  • Loading branch information
jensens committed Oct 18, 2016
2 parents c0e93b1 + 0c95461 commit ce1285f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ Bug fixes:
- Add coding headers on python files.
[gforcada]

- More flexible test of getIcon.
[jensens]


1.6.4 (2016-08-12)
------------------

Expand Down
6 changes: 3 additions & 3 deletions src/plone/app/blob/tests/test_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,11 @@ def testRangeSupport(self):
def testIcon(self):
blob = self.folder.blob
blob.update(file=getImage())
self.assertEqual(blob.getIcon(), 'plone/image.png')
self.assertTrue(blob.getIcon().endswith('image.png'))
blob.update(file=pdf_data)
self.assertEqual(blob.getIcon(), 'plone/pdf.png')
self.assertTrue(blob.getIcon().endswith('pdf.png'))
blob.update(file='some text...')
self.assertEqual(blob.getIcon(), 'plone/txt.png')
self.assertTrue(blob.getIcon().endswith('txt.png'))

def testIconLookupForUnknownMimeType(self):
""" test for http://plone.org/products/plone.app.blob/issues/1 """
Expand Down

0 comments on commit ce1285f

Please sign in to comment.