From: david-sarah Date: Sun, 18 Jul 2010 00:01:23 +0000 (-0700) Subject: test_cli.py: fix error that crept in when rebasing the patch for #1072. X-Git-Url: https://git.rkrishnan.org/vdrive/%22file:/frontends/statistics?a=commitdiff_plain;h=0d79a4a7d14e46895184623168651116178f7f82;p=tahoe-lafs%2Ftahoe-lafs.git test_cli.py: fix error that crept in when rebasing the patch for #1072. --- diff --git a/src/allmydata/test/test_cli.py b/src/allmydata/test/test_cli.py index 05d49331..f52e468e 100644 --- a/src/allmydata/test/test_cli.py +++ b/src/allmydata/test/test_cli.py @@ -2435,9 +2435,6 @@ class Rm(GridTestMixin, CLITestMixin, unittest.TestCase): def test_rm_without_alias(self): # 'tahoe rm' should behave sensibly when invoked without an explicit # alias before the default 'tahoe' alias has been created. - - d.addCallback(lambda ign: self.do_cli("unlink", "afile")) - d.addCallback(_check) self.basedir = "cli/Rm/rm_without_alias" self.set_up_grid() d = self.do_cli("rm", "afile") @@ -2446,15 +2443,15 @@ class Rm(GridTestMixin, CLITestMixin, unittest.TestCase): self.failUnlessIn("error:", err) self.failUnlessReallyEqual(out, "") d.addCallback(_check) + + d.addCallback(lambda ign: self.do_cli("unlink", "afile")) + d.addCallback(_check) return d def test_rm_with_nonexistent_alias(self): # 'tahoe rm' should behave sensibly when invoked with an explicit # alias that doesn't exist. self.basedir = "cli/Rm/rm_with_nonexistent_alias" - - d.addCallback(lambda ign: self.do_cli("unlink", "nonexistent:afile")) - d.addCallback(_check) self.set_up_grid() d = self.do_cli("rm", "nonexistent:afile") def _check((rc, out, err)): @@ -2463,6 +2460,9 @@ class Rm(GridTestMixin, CLITestMixin, unittest.TestCase): self.failUnlessIn("nonexistent", err) self.failUnlessReallyEqual(out, "") d.addCallback(_check) + + d.addCallback(lambda ign: self.do_cli("unlink", "nonexistent:afile")) + d.addCallback(_check) return d