mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-20 21:43:09 +00:00
test/test_upload.py: changes to test plumbing for #1117 tests
- Add a callRemoteOnly method to FakeBucketWriter. - Change the abort method in FakeBucketWriter to not return a RuntimeError.
This commit is contained in:
parent
6d2c216b8f
commit
5becaf0309
@ -158,6 +158,13 @@ class FakeBucketWriter:
|
||||
d.addCallback(lambda res: _call())
|
||||
return d
|
||||
|
||||
|
||||
def callRemoteOnly(self, methname, *args, **kwargs):
|
||||
d = self.callRemote(methname, *args, **kwargs)
|
||||
del d # callRemoteOnly ignores this
|
||||
return None
|
||||
|
||||
|
||||
def remote_write(self, offset, data):
|
||||
precondition(not self.closed)
|
||||
precondition(offset >= 0)
|
||||
@ -172,7 +179,7 @@ class FakeBucketWriter:
|
||||
self.closed = True
|
||||
|
||||
def remote_abort(self):
|
||||
log.err(RuntimeError("uh oh, I was asked to abort"))
|
||||
pass
|
||||
|
||||
class FakeClient:
|
||||
DEFAULT_ENCODING_PARAMETERS = {"k":25,
|
||||
|
Loading…
Reference in New Issue
Block a user