Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1611)

Unified Diff: tests/parsers/winfirewall.py

Issue 338460043: [plaso] Refactored timestamp checks in tests #1701 (Closed)
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/parsers/winevtx.py ('k') | tests/parsers/winjob.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/parsers/winfirewall.py
diff --git a/tests/parsers/winfirewall.py b/tests/parsers/winfirewall.py
index c9bb505a6b705dc631a71f2d64b5158fdaa6503d..0452287db315df794c42008527916725080b7f09 100644
--- a/tests/parsers/winfirewall.py
+++ b/tests/parsers/winfirewall.py
@@ -7,7 +7,6 @@ from __future__ import unicode_literals
import unittest
from plaso.formatters import winfirewall as _ # pylint: disable=unused-import
-from plaso.lib import timelib
from plaso.parsers import winfirewall
from tests import test_lib as shared_test_lib
@@ -29,18 +28,14 @@ class WinFirewallParserTest(test_lib.ParserTestCase):
event = events[4]
- expected_timestamp = timelib.Timestamp.CopyFromString(
- '2005-04-11 08:06:02')
- self.assertEqual(event.timestamp, expected_timestamp)
+ self.CheckTimestamp(event.timestamp, '2005-04-11 08:06:02.000000')
self.assertEqual(event.source_ip, '123.45.78.90')
self.assertEqual(event.dest_ip, '123.156.78.90')
event = events[7]
- expected_timestamp = timelib.Timestamp.CopyFromString(
- '2005-04-11 08:06:26')
- self.assertEqual(event.timestamp, expected_timestamp)
+ self.CheckTimestamp(event.timestamp, '2005-04-11 08:06:26.000000')
self.assertEqual(event.size, 576)
self.assertEqual(event.flags, 'A')
« no previous file with comments | « tests/parsers/winevtx.py ('k') | tests/parsers/winjob.py » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b