Skip to content

Commit

Permalink
Regression test for #1793
Browse files Browse the repository at this point in the history
(cherry picked from commit adb586a)
  • Loading branch information
kevinbackhouse authored and mergify-bot committed Aug 7, 2021
1 parent 13c4b14 commit 41708c9
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
Binary file added test/data/issue_1793_poc.heic
Binary file not shown.
32 changes: 32 additions & 0 deletions tests/bugfixes/github/test_issue_1793.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# -*- coding: utf-8 -*-

import system_tests
import unittest

# test needs system_tests.BT.vv['enable_bmff']=1
bSkip=system_tests.BT.verbose_version().get('enable_bmff')!='1'
if bSkip:
raise unittest.SkipTest('*** requires enable_bmff=1 ***')

class BmffImageboxHandlerLargeAllocation(metaclass=system_tests.CaseMeta):
"""
Regression test for the bug described in:
https://github.com/Exiv2/exiv2/issues/1793
"""
url = "https://github.com/Exiv2/exiv2/issues/1793"
filename = "$data_path/issue_1793_poc.heic"

if bSkip:
commands=[]
retval=[]
stdin=[]
stderr=[]
stdout=[]
print("*** test skipped. requires enable_bmff=1***")
else:
commands = ["$exiv2 $filename"]
stdout = [""]
stderr = ["""Exiv2 exception in print action for file $filename:
$kerCorruptedMetadata
"""]
retval = [1]

0 comments on commit 41708c9

Please sign in to comment.