X-Git-Url: http://www.wagner.pp.ru/gitweb/?a=blobdiff_plain;f=tests%2Ftestrand.py;fp=tests%2Ftestrand.py;h=853a4916f973716d2dbb85d8583b0e90dfc0e034;hb=954b6dc9e3312f8d8b49f20f8466e6d2a8342f35;hp=ec861ba201cc3963745a83fe755db7a48c5a00cc;hpb=3ddc0864d900227434283bfc5956e0c4342a6b01;p=oss%2Fctypescrypto.git diff --git a/tests/testrand.py b/tests/testrand.py index ec861ba..853a491 100644 --- a/tests/testrand.py +++ b/tests/testrand.py @@ -2,27 +2,27 @@ from ctypescrypto.rand import * import unittest class TestRand(unittest.TestCase): - def test_bytes(self): - b=bytes(100) - self.assertEqual(len(b),100) - b2=bytes(100) - self.assertNotEqual(b,b2) - def test_pseudo_bytes(self): - b=pseudo_bytes(100) - self.assertEqual(len(b),100) - b2=pseudo_bytes(100) - self.assertNotEqual(b,b2) - def test_seed(self): - b="aaqwrwfsagdsgdsfgdsfgdfsgdsfgdsgfdsfgdsfg" - seed(b) - # Check if no segfault here - def test_entropy(self): - b="aaqwrwfsagdsgdsfgdsfgdfsgdsfgdsgfdsfgdsfg" - seed(b,2.25) - # Check if no segfault here - def test_Status(self): - i=status() - self.assertEqual(i,1) + def test_bytes(self): + b=bytes(100) + self.assertEqual(len(b),100) + b2=bytes(100) + self.assertNotEqual(b,b2) + def test_pseudo_bytes(self): + b=pseudo_bytes(100) + self.assertEqual(len(b),100) + b2=pseudo_bytes(100) + self.assertNotEqual(b,b2) + def test_seed(self): + b="aaqwrwfsagdsgdsfgdsfgdfsgdsfgdsgfdsfgdsfg" + seed(b) + # Check if no segfault here + def test_entropy(self): + b="aaqwrwfsagdsgdsfgdsfgdfsgdsfgdsgfdsfgdsfg" + seed(b,2.25) + # Check if no segfault here + def test_Status(self): + i=status() + self.assertEqual(i,1) if __name__ == '__main__': - unittest.main() + unittest.main()