Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_increase_seq(self):
"""Verifies Communicator can increase sequence number correctly"""
self.assertEqual(executor.Communicator.increase_seq(1), 2, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(100), 101, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(0xFFFF), 1,
'Not returned to 1 when exceeding sequence number maximum length')
self.assertEqual(executor.Communicator.increase_seq(0xFFFE), 0xFFFF,
'Increasing sequence number 0xFFFE did not return 0xFFFF')
def test_increase_seq(self):
"""Verifies Communicator can increase sequence number correctly"""
self.assertEqual(executor.Communicator.increase_seq(1), 2, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(100), 101, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(0xFFFF), 1,
'Not returned to 1 when exceeding sequence number maximum length')
self.assertEqual(executor.Communicator.increase_seq(0xFFFE), 0xFFFF,
'Increasing sequence number 0xFFFE did not return 0xFFFF')
def test_increase_seq(self):
"""Verifies Communicator can increase sequence number correctly"""
self.assertEqual(executor.Communicator.increase_seq(1), 2, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(100), 101, 'Increasing sequence number 1 did not return 2')
self.assertEqual(executor.Communicator.increase_seq(0xFFFF), 1,
'Not returned to 1 when exceeding sequence number maximum length')
self.assertEqual(executor.Communicator.increase_seq(0xFFFE), 0xFFFF,
'Increasing sequence number 0xFFFE did not return 0xFFFF')