diff --git a/certbot/cli.py b/certbot/cli.py index 6460dcb4c..d353f5402 100644 --- a/certbot/cli.py +++ b/certbot/cli.py @@ -393,6 +393,8 @@ class HelpfulArgumentParser(object): ("Conflicting values for displayer." " {0} conflicts with dialog_mode").format(arg) ) + elif parsed_args.verbose_count > flag_default("verbose_count"): + parsed_args.text_mode = True if parsed_args.validate_hooks: hooks.validate_hooks(parsed_args) diff --git a/certbot/tests/cli_test.py b/certbot/tests/cli_test.py index 896550837..cb32975e4 100644 --- a/certbot/tests/cli_test.py +++ b/certbot/tests/cli_test.py @@ -1020,6 +1020,12 @@ class CLITest(unittest.TestCase): # pylint: disable=too-many-public-methods args = ['renew', '--dialog', '--text'] self.assertRaises(errors.Error, self._call, args) + def test_text_mode_when_verbose(self): + parse = self._get_argument_parser() + short_args = ['-v'] + namespace = parse(short_args) + self.assertTrue(namespace.text_mode) + class DetermineAccountTest(unittest.TestCase): """Tests for certbot.cli._determine_account."""