Commit 821e31bb authored by Chris McDonough's avatar Chris McDonough

Iterator interface had inappropriate self args.

parent 00578f52
......@@ -14,13 +14,13 @@ class IStreamIterator(Interface):
but it has a chance of going insane if it happens to be loading
or storing something in the other thread at the same time. """
def next(self):
def next():
"""
Return a sequence of bytes out of the bytestream, or raise
StopIeration if we've reached the end of the bytestream.
"""
def __len__(self):
def __len__():
"""
Return an integer representing the length of the object
in bytes.
......
import unittest
from Interface.Verify import verifyClass
from ZPublisher.Iterators import IStreamIterator, filestream_iterator
class TestFileStreamIterator(unittest.TestCase):
def testInterface(self):
verifyClass(IStreamIterator, filestream_iterator)
def test_suite():
suite = unittest.TestSuite()
suite.addTest( unittest.makeSuite( TestFileStreamIterator ) )
return suite
def main():
unittest.main(defaultTest='test_suite')
if __name__ == '__main__':
main()
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment