From: Daira Hopwood <daira@jacaranda.org>
Date: Thu, 5 Sep 2013 16:51:28 +0000 (+0100)
Subject: Thu May 31 23:23:07 BST 2012  david-sarah@jacaranda.org
X-Git-Url: https://git.rkrishnan.org/vdrive/%5B/%5D%20/...?a=commitdiff_plain;h=53914bceb90acaceff2cf22c970cff065b460d28;p=tahoe-lafs%2Ftahoe-lafs.git

Thu May 31 23:23:07 BST 2012  david-sarah@jacaranda.org
  * Restore --rterrors option to 'setup.py test' and 'setup.py trial' to keep buildbots happy. refs #1699
---

diff --git a/setup.py b/setup.py
index 559a934d..6914bca1 100644
--- a/setup.py
+++ b/setup.py
@@ -188,6 +188,7 @@ class Trial(Command):
     description = "run trial (use 'bin%stahoe debug trial' for the full set of trial options)" % (os.sep,)
     # This is just a subset of the most useful options, for compatibility.
     user_options = [ ("no-rterrors", None, "Don't print out tracebacks as they occur."),
+                     ("rterrors", "e", "Print out tracebacks as they occur (default, so ignored)."),
                      ("until-failure", "u", "Repeat a test (specified by -s) until it fails."),
                      ("reporter=", None, "The reporter to use for this test run."),
                      ("suite=", "s", "Specify the test suite."),
@@ -195,6 +196,7 @@ class Trial(Command):
                    ]
 
     def initialize_options(self):
+        self.rterrors = False
         self.no_rterrors = False
         self.until_failure = False
         self.reporter = None
@@ -209,6 +211,8 @@ class Trial(Command):
         if not self.quiet:
             args.append('--version-and-path')
         args += ['debug', 'trial']
+        if self.rterrors and self.no_rterrors:
+            raise AssertionError("--rterrors and --no-rterrors conflict.")
         if not self.no_rterrors:
             args.append('--rterrors')
         if self.until_failure: