From 74c1893ce3ed090c4018e8281a141c326511fcf4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Thu, 22 Mar 2018 01:47:41 +0100 Subject: [PATCH] tests: fix firewall tests after 6e8e48e3 "Avoid UTC datetime" --- qubes/tests/firewall.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qubes/tests/firewall.py b/qubes/tests/firewall.py index ad02afc4..8a89bb8c 100644 --- a/qubes/tests/firewall.py +++ b/qubes/tests/firewall.py @@ -300,7 +300,7 @@ class TC_06_Expire(qubes.tests.QubesTestCase): self.assertEqual(str(instance), '1463292452') self.assertEqual(instance.api_rule, 'expire=1463292452') self.assertEqual(instance.datetime, - datetime.datetime(2016, 5, 15, 6, 7, 32)) + datetime.datetime.fromtimestamp(1463292452)) self.assertIsNone(instance.rule) def test_001_str(self): @@ -308,7 +308,7 @@ class TC_06_Expire(qubes.tests.QubesTestCase): instance = qubes.firewall.Expire('1463292452') self.assertEqual(str(instance), '1463292452') self.assertEqual(instance.datetime, - datetime.datetime(2016, 5, 15, 6, 7, 32)) + datetime.datetime.fromtimestamp(1463292452)) self.assertIsNone(instance.rule) def test_002_invalid(self):