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

Unified Diff: tests/parsers/sqlite_plugins/ls_quarantine.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/sqlite_plugins/kik_ios.py ('k') | tests/parsers/sqlite_plugins/mac_document_versions.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/parsers/sqlite_plugins/ls_quarantine.py
diff --git a/tests/parsers/sqlite_plugins/ls_quarantine.py b/tests/parsers/sqlite_plugins/ls_quarantine.py
index 86c5a60959e120f0987fab4dfe9565b4562bd7fb..958f97cda123084ed2c3d89a94a407ac1dd52a5a 100644
--- a/tests/parsers/sqlite_plugins/ls_quarantine.py
+++ b/tests/parsers/sqlite_plugins/ls_quarantine.py
@@ -7,7 +7,6 @@ from __future__ import unicode_literals
import unittest
from plaso.formatters import ls_quarantine as _ # pylint: disable=unused-import
-from plaso.lib import timelib
from plaso.parsers.sqlite_plugins import ls_quarantine
from tests import test_lib as shared_test_lib
@@ -32,9 +31,7 @@ class LSQuarantinePluginTest(test_lib.SQLitePluginTestCase):
# Examine a VLC event.
event = events[3]
- expected_timestamp = timelib.Timestamp.CopyFromString(
- '2013-07-08 21:12:03')
- self.assertEqual(event.timestamp, expected_timestamp)
+ self.CheckTimestamp(event.timestamp, '2013-07-08 21:12:03.000000')
self.assertEqual(event.agent, 'Google Chrome')
expected_url = (
@@ -47,16 +44,12 @@ class LSQuarantinePluginTest(test_lib.SQLitePluginTestCase):
# Examine a MacKeeper event.
event = events[9]
- expected_timestamp = timelib.Timestamp.CopyFromString(
- '2013-07-12 19:28:58')
- self.assertEqual(event.timestamp, expected_timestamp)
+ self.CheckTimestamp(event.timestamp, '2013-07-12 19:28:58.000000')
# Examine a SpeedTest event.
event = events[10]
- expected_timestamp = timelib.Timestamp.CopyFromString(
- '2013-07-12 19:30:16')
- self.assertEqual(event.timestamp, expected_timestamp)
+ self.CheckTimestamp(event.timestamp, '2013-07-12 19:30:16.000000')
expected_message = (
'[Google Chrome] Downloaded: http://mackeeperapp.zeobit.com/aff/'
« no previous file with comments | « tests/parsers/sqlite_plugins/kik_ios.py ('k') | tests/parsers/sqlite_plugins/mac_document_versions.py » ('j') | no next file with comments »

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