Progress on removing TelegramParserV2_2 and TelegramParserV4 in favor of a generic TelegramParser

This commit is contained in:
Nigel Dokter
2017-01-20 23:02:19 +01:00
parent e2e4bb36a2
commit 07634abed1
7 changed files with 70 additions and 128 deletions

View File

@@ -4,7 +4,7 @@ import unittest
from dsmr_parser import obis_references as obis
from dsmr_parser import telegram_specifications
from dsmr_parser.parsers import TelegramParserV2_2
from dsmr_parser.parsers import TelegramParser
from dsmr_parser.clients.protocol import DSMRProtocol
@@ -35,10 +35,7 @@ TELEGRAM_V2_2 = (
class ProtocolTest(unittest.TestCase):
def setUp(self):
parser = TelegramParserV2_2
specification = telegram_specifications.V2_2
telegram_parser = parser(specification)
telegram_parser = TelegramParser(telegram_specifications.V2_2)
self.protocol = DSMRProtocol(None, telegram_parser,
telegram_callback=Mock())