Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 77cf8e5914
Fetching contributors…

Cannot retrieve contributors at this time

file 31 lines (21 sloc) 0.886 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
# -*- coding: utf-8 -*-

#This file was originally generated by PyScripter's unitest wizard

import unittest
from crypt_sqlyog import DecodePassword, EncodePassword

class TestGlobalFunctions(unittest.TestCase):
    def setUp(self):
        self.b_pass = '1234567890'
        self.c_pass = 'mBmZGpobmxycGA=='

    def tearDown(self):
        del self.b_pass
        del self.c_pass

    def testDecodePassword(self):
        self.assertEqual(DecodePassword(self.c_pass), self.b_pass)

    def testEncodePassword(self):
        self.assertEqual(EncodePassword(self.b_pass), self.c_pass)

    def testEncodeDecodePassword(self):
        self.assertEqual(DecodePassword(EncodePassword(self.b_pass)), self.b_pass)

    def testDecodeEncodePassword(self):
        self.assertEqual(EncodePassword(DecodePassword(self.c_pass)), self.c_pass)


if __name__ == '__main__':
    unittest.main()
Something went wrong with that request. Please try again.