From c8f18830c9c6fb513d2f687206facb7ef792a43a Mon Sep 17 00:00:00 2001
From: Bruce Flynn <brucef@ssec.wisc.edu>
Date: Fri, 4 Jul 2014 08:45:10 -0500
Subject: [PATCH] Fix test for v2

---
 aosstower/tests/l00/test_parser.py | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/aosstower/tests/l00/test_parser.py b/aosstower/tests/l00/test_parser.py
index c7e9b76..1424f10 100644
--- a/aosstower/tests/l00/test_parser.py
+++ b/aosstower/tests/l00/test_parser.py
@@ -31,15 +31,15 @@ class ParserV0Tests(unittest.TestCase):
         self.assertEqual(record['stamp'], datetime(1970, 1, 1))
 
 
-class ParserV1Tests(unittest.TestCase):
+class ParserV1V2Tests(unittest.TestCase):
 
     line = ("1,1970,1,0000,0,976.59,5.8564,30.085,25.893,977.36,58732,"
             "47.375,24.234,23.865,22.615,37.219,6.9222,67.398,145.2,45.581,"
             "22.669,10.417,145.2,22.665,163.94,0,0,30.015,29.89\n")
 
     def _cut(self):
-        from aosstower.l00.parser import ParserV1
-        return ParserV1()
+        from aosstower.l00.parser import ParserV1V2
+        return ParserV1V2()
 
     def test_maybe_mine(self):
         parser = self._cut()
@@ -56,3 +56,8 @@ class ParserV1Tests(unittest.TestCase):
         self.assertIn('stamp', record)
         self.assertEqual(record['stamp'], datetime(1970, 1, 1))
 
+    def test_record_supports_v1_and_v2(self):
+        parser = self._cut()
+
+        parser.parse(self.line)
+        parser.parse(self.line.strip() + ',999\n')
-- 
GitLab