mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-29 17:28:53 +00:00
more allmydata.util test coverage, rename the test case to be more correct
This commit is contained in:
parent
1a4cf6f7b7
commit
d432099880
@ -14,6 +14,7 @@ class IDLib(unittest.TestCase):
|
|||||||
self.failUnlessEqual(idlib.b2a_or_none("\x12\x34"), "ci2a====")
|
self.failUnlessEqual(idlib.b2a_or_none("\x12\x34"), "ci2a====")
|
||||||
def test_a2b(self):
|
def test_a2b(self):
|
||||||
self.failUnlessEqual(idlib.a2b("ci2a===="), "\x12\x34")
|
self.failUnlessEqual(idlib.a2b("ci2a===="), "\x12\x34")
|
||||||
|
self.failUnlessRaises(TypeError, idlib.a2b, "bogus")
|
||||||
def test_peerid(self):
|
def test_peerid(self):
|
||||||
# these are 160-bit numbers
|
# these are 160-bit numbers
|
||||||
peerid = "\x80" + "\x00" * 19
|
peerid = "\x80" + "\x00" * 19
|
Loading…
Reference in New Issue
Block a user