Skip to content

Commit

Permalink
Add sample name to unittest fail message.
Browse files Browse the repository at this point in the history
Should help debugging unexpected results.
  • Loading branch information
christian-intra2net committed May 31, 2024
1 parent 2127af0 commit 0550fd1
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions tests/oleid/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,14 @@ def test_properties(self):
continue
else:
self.assertEqual(value_dict['codepage'],
'1252: ANSI Latin 1; Western European (Windows)')
'1252: ANSI Latin 1; Western European (Windows)',
'Unexpected result {0!r} for codepage of sample {1}'
.format(value_dict['codepage'], filename))
self.assertIn(value_dict['author'],
(b'user', b'schulung',
b'xxxxxxxxxxxx', b'zzzzzzzzzzzz'))
b'xxxxxxxxxxxx', b'zzzzzzzzzzzz'),
'Unexpected result {0!r} for author of sample {1}'
.format(value_dict['author'], filename))

def test_encrypted(self):
"""Test indicator "encrypted"."""
Expand Down

0 comments on commit 0550fd1

Please sign in to comment.