[Zodb-checkins] CVS: ZODB3/BTrees - check.py:1.1.2.2
Tim Peters
tim.one@comcast.net
Tue, 14 Jan 2003 17:32:52 -0500
Update of /cvs-repository/ZODB3/BTrees
In directory cvs.zope.org:/tmp/cvs-serv12199/BTrees
Modified Files:
Tag: ZODB3-3_1-branch
check.py
Log Message:
Removed obsolete "by eyeball" test cruft.
=== ZODB3/BTrees/check.py 1.1.2.1 => 1.1.2.2 ===
--- ZODB3/BTrees/check.py:1.1.2.1 Tue Jan 14 17:25:12 2003
+++ ZODB3/BTrees/check.py Tue Jan 14 17:32:49 2003
@@ -412,24 +412,3 @@
def display(btree):
"Display the internal structure of a BTree, Bucket, TreeSet or Set."
Printer(btree).display()
-
-def _test():
- t = OOBTree()
- for i in range(31):
- t[i] = 2*i
- display(t)
- check(t)
- s = t.__getstate__()
- # Looks like (state, first_bucket)
- # where state looks like (bucket0, 15, bucket1).
- assert len(s) == 2
- assert len(s[0]) == 3
- assert s[0][1] == 15
- # Damage an invariant by dropping the BTree key to 14.
- news = (s[0][0], 14, s[0][2]), s[1]
- t.__setstate__(news)
- display(t)
- check(t)
-
-if __name__ == "__main__":
- _test()