Commit ca7c8812 authored by Jim Fulton's avatar Jim Fulton

Added test for not opening blobs that are already opened for writing.

parent 66ac1545
...@@ -78,6 +78,19 @@ Now we can open it for writing again and e.g. append data: ...@@ -78,6 +78,19 @@ Now we can open it for writing again and e.g. append data:
>>> f4 = myblob.open("a") >>> f4 = myblob.open("a")
>>> f4.write("\nBlob is fine.") >>> f4.write("\nBlob is fine.")
We can't open a blob while it is open for writing:
>>> myblob.open("w")
Traceback (most recent call last):
...
BlobError: Already opened for writing.
>>> myblob.open("r")
Traceback (most recent call last):
...
BlobError: Already opened for writing.
>>> f4.close() >>> f4.close()
Now we can read it: Now we can read it:
......
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