Left: | ||
Right: |
OLD | NEW |
---|---|
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # -*- coding: utf-8 -*- | 2 # -*- coding: utf-8 -*- |
3 """Tests for Basic Security Module (BSM) file parser.""" | 3 """Tests for Basic Security Module (BSM) file parser.""" |
4 | 4 |
5 from __future__ import unicode_literals | 5 from __future__ import unicode_literals |
6 | 6 |
7 import unittest | 7 import unittest |
8 | 8 |
9 from plaso.formatters import bsm as _ # pylint: disable=unused-import | 9 from plaso.formatters import bsm as _ # pylint: disable=unused-import |
10 from plaso.lib import definitions | 10 from plaso.lib import definitions |
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
287 'error': | 287 'error': |
288 'Argument list too long', | 288 'Argument list too long', |
289 'token_status': 7}, | 289 'token_status': 7}, |
290 'BSM_TOKEN_TRAILER': 31} | 290 'BSM_TOKEN_TRAILER': 31} |
291 ] | 291 ] |
292 | 292 |
293 for event_index in range(0, 19): | 293 for event_index in range(0, 19): |
294 event = events[event_index] | 294 event = events[event_index] |
295 expected_extra_tokens_dict = expected_extra_tokens[event_index] | 295 expected_extra_tokens_dict = expected_extra_tokens[event_index] |
296 extra_tokens_dict = getattr(event, 'extra_tokens', {}) | 296 extra_tokens_dict = getattr(event, 'extra_tokens', {}) |
297 self.assertDictContains(extra_tokens_dict, expected_extra_tokens_dict) | 297 self.AssertDictContains(extra_tokens_dict, expected_extra_tokens_dict) |
Joachim Metz
2018/01/10 20:37:24
I opt to not use the unittest naming convention he
Joachim Metz
2018/01/10 20:38:31
or make the method "protected" _AssertDictContains
onager
2018/01/11 12:58:04
Done.
onager
2018/01/11 12:58:04
Done.
| |
298 | 298 |
299 | 299 |
300 if __name__ == '__main__': | 300 if __name__ == '__main__': |
301 unittest.main() | 301 unittest.main() |
OLD | NEW |