mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-22 22:32:23 +00:00
test_upload.py: implement remote_abort on our fake BucketWriter
This commit is contained in:
parent
8661c94f17
commit
1ff21d1d64
@ -2,6 +2,7 @@
|
|||||||
import os
|
import os
|
||||||
from twisted.trial import unittest
|
from twisted.trial import unittest
|
||||||
from twisted.python.failure import Failure
|
from twisted.python.failure import Failure
|
||||||
|
from twisted.python import log
|
||||||
from twisted.internet import defer
|
from twisted.internet import defer
|
||||||
from cStringIO import StringIO
|
from cStringIO import StringIO
|
||||||
|
|
||||||
@ -133,6 +134,9 @@ class FakeBucketWriter:
|
|||||||
precondition(not self.closed)
|
precondition(not self.closed)
|
||||||
self.closed = True
|
self.closed = True
|
||||||
|
|
||||||
|
def remote_abort(self):
|
||||||
|
log.err("uh oh, I was asked to abort")
|
||||||
|
|
||||||
class FakeClient:
|
class FakeClient:
|
||||||
DEFAULT_ENCODING_PARAMETERS = {"k":25,
|
DEFAULT_ENCODING_PARAMETERS = {"k":25,
|
||||||
"happy": 75,
|
"happy": 75,
|
||||||
|
Loading…
Reference in New Issue
Block a user