changeset 26068:05e7f57c74ac

hghave: remove quiet option The --quiet flag appears to be unused. Kill it.
author Gregory Szorc <gregory.szorc@gmail.com>
date Sat, 22 Aug 2015 10:37:38 -0700
parents 8107c308ff22
children 09d6725cbc60
files tests/hghave tests/hghave.py
diffstat 2 files changed, 12 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/tests/hghave	Sat Aug 22 10:28:34 2015 -0700
+++ b/tests/hghave	Sat Aug 22 10:37:38 2015 -0700
@@ -30,10 +30,8 @@
                   help="test available features")
 parser.add_option("--list-features", action="store_true",
                   help="list available features")
-parser.add_option("-q", "--quiet", action="store_true",
-                  help="check features silently")
 
-def _loadaddon(quiet):
+def _loadaddon():
     if 'TESTDIR' in os.environ:
         # loading from '.' isn't needed, because `hghave` should be
         # running at TESTTMP in this case
@@ -48,15 +46,14 @@
     try:
         import hghaveaddon
     except BaseException, inst:
-        if not quiet:
-            sys.stderr.write('failed to import hghaveaddon.py from %r: %s\n'
-                             % (path, inst))
+        sys.stderr.write('failed to import hghaveaddon.py from %r: %s\n'
+                         % (path, inst))
         sys.exit(2)
     sys.path.pop(0)
 
 if __name__ == '__main__':
     options, args = parser.parse_args()
-    _loadaddon(options.quiet)
+    _loadaddon()
     if options.list_features:
         list_features()
         sys.exit(0)
@@ -64,4 +61,4 @@
     if options.test_features:
         sys.exit(test_features())
 
-    hghave.require(args, options.quiet)
+    hghave.require(args)
--- a/tests/hghave.py	Sat Aug 22 10:28:34 2015 -0700
+++ b/tests/hghave.py	Sat Aug 22 10:37:38 2015 -0700
@@ -47,17 +47,16 @@
 
     return result
 
-def require(features, quiet=False):
+def require(features):
     """Require that features are available, exiting if not."""
     result = checkfeatures(features)
 
-    if not quiet:
-        for missing in result['missing']:
-            sys.stderr.write('skipped: unknown feature: %s\n' % missing)
-        for msg in result['skipped']:
-            sys.stderr.write('skipped: %s\n' % msg)
-        for msg in result['error']:
-            sys.stderr.write('%s\n' % msg)
+    for missing in result['missing']:
+        sys.stderr.write('skipped: unknown feature: %s\n' % missing)
+    for msg in result['skipped']:
+        sys.stderr.write('skipped: %s\n' % msg)
+    for msg in result['error']:
+        sys.stderr.write('%s\n' % msg)
 
     if result['missing']:
         sys.exit(2)