def testTftpPacketOACK(self):
    log.debug('===> Running testcase testTftpPacketOACK')
    oack = tftpy.TftpPacketOACK()
    oack.options = {'blksize': 2048}
    oack.encode()
    self.assert_((oack.buffer != None), 'Buffer populated')
    oack.decode()
    self.assertEqual(oack.opcode, 6, 'OACK opcode is correct')
    self.assertEqual(oack.options['blksize'], '2048', 'OACK blksize option is correct')
    oack.options = {'blksize': '4096'}
    oack.encode()
    self.assert_((oack.buffer != None), 'Buffer populated')
    oack.decode()
    self.assertEqual(oack.opcode, 6, 'OACK opcode is correct')
    self.assertEqual(oack.options['blksize'], '4096', 'OACK blksize option is correct')
def testTftpPacketOACK(self):
    log.debug('===> Running testcase testTftpPacketOACK')
    oack = tftpy.TftpPacketOACK()
    oack.options = {'blksize': 2048}
    oack.encode()
    self.assert_((oack.buffer != None), 'Buffer populated')
    oack.decode()
    self.assertEqual(oack.opcode, 6, 'OACK opcode is correct')
    self.assertEqual(oack.options['blksize'], '2048', 'OACK blksize option is correct')
    oack.options = {'blksize': '4096'}
    oack.encode()
    self.assert_((oack.buffer != None), 'Buffer populated')
    oack.decode()
    self.assertEqual(oack.opcode, 6, 'OACK opcode is correct')
    self.assertEqual(oack.options['blksize'], '4096', 'OACK blksize option is correct')