From: Daira Hopwood Date: Wed, 15 May 2013 13:14:12 +0000 (+0100) Subject: Improvements to test refs #1742 X-Git-Tag: allmydata-tahoe-1.10.1a1~241 X-Git-Url: https://git.rkrishnan.org/simplejson/%3C?a=commitdiff_plain;h=refs%2Fheads%2F1742-error-during-post;p=tahoe-lafs%2Ftahoe-lafs.git Improvements to test refs #1742 Signed-off-by: Daira Hopwood --- diff --git a/src/allmydata/test/test_mutable.py b/src/allmydata/test/test_mutable.py index a8bf4ee1..fb39af72 100644 --- a/src/allmydata/test/test_mutable.py +++ b/src/allmydata/test/test_mutable.py @@ -1330,19 +1330,20 @@ class Roundtrip(unittest.TestCase, testutil.ShouldFailMixin, PublishMixin): d.addCallback(_remove_shares) return d - def test_all_shares_vanished_new_servermap(self): + def test_all_but_two_shares_vanished_updated_servermap(self): + # tests error reporting for ticket #1742 d = self.make_servermap() def _remove_shares(servermap): self._version = servermap.best_recoverable_version() for shares in self._storage._peers.values()[2:]: shares.clear() - return self.make_servermap() + return self.make_servermap(servermap) d.addCallback(_remove_shares) - def _check(new_servermap): + def _check(updated_servermap): d1 = self.shouldFail(NotEnoughSharesError, - "test_all_shares_vanished", + "test_all_but_two_shares_vanished_updated_servermap", "ran out of servers", - self.do_download, new_servermap, version=self._version) + self.do_download, updated_servermap, version=self._version) return d1 d.addCallback(_check) return d