From 4240393804449026341a1c5a052d99ae76d835c0 Mon Sep 17 00:00:00 2001 From: MMGen Date: Tue, 26 Mar 2019 13:02:09 +0000 Subject: [PATCH] minor fixes --- mmgen/opts.py | 2 +- scripts/test-release.sh | 8 +++++--- test/pexpect.py | 2 +- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/mmgen/opts.py b/mmgen/opts.py index cd7a25a7..2a10a98e 100755 --- a/mmgen/opts.py +++ b/mmgen/opts.py @@ -63,7 +63,7 @@ def opt_postproc_debug(): Msg(' Opts after processing:') for k in a: v = getattr(opt,k) - Msg(' {:18}: {:<6} [{}]'.format(k,v,type(v).__name__)) + Msg(' {:18}: {!r:<6} [{}]'.format(k,v,type(v).__name__)) Msg(" Opts set to 'None':") Msg(' {}\n'.format('\n '.join(b))) Msg(' Global vars:') diff --git a/scripts/test-release.sh b/scripts/test-release.sh index 9a0b4d5a..3f9acfa1 100755 --- a/scripts/test-release.sh +++ b/scripts/test-release.sh @@ -30,19 +30,21 @@ while getopts hbCfiIlOpRtvV OPT do case "$OPT" in h) printf " %-16s Test MMGen release\n" "${PROGNAME}:" - echo " USAGE: $PROGNAME [options] [branch] [tests]" + echo " USAGE: $PROGNAME [options] [tests]" echo " OPTIONS: '-h' Print this help message" echo " '-b' Buffer keypresses for all invocations of 'test/test.py'" echo " '-C' Run tests in coverage mode" echo " '-f' Speed up the tests by using fewer rounds" - echo " '-i' Create and install Python package, then run tests" + echo " '-i' Create and install Python package, then run tests. A branch" + echo " must be supplied as the first argument" echo " '-I' Install the package only; don't run tests" echo " '-l' List the test name symbols" echo " '-O' Use pexpect.spawn rather than popen_spawn for applicable tests" echo " '-p' Pause between tests" echo " '-R' Don't remove temporary files after program has exited" echo " '-t' Print the tests without running them" - echo " '-v' Run test/test.py with '--exact-output' and other commands with '--verbose' switch" + echo " '-v' Run test/test.py with '--exact-output' and other commands with" + echo " '--verbose' switch" echo " '-V' Run test/test.py and other commands with '--verbose' switch" echo " AVAILABLE TESTS:" echo " obj - data objects" diff --git a/test/pexpect.py b/test/pexpect.py index c75082c6..66829122 100755 --- a/test/pexpect.py +++ b/test/pexpect.py @@ -151,7 +151,7 @@ class MMGenPexpect(object): # readline() of partial lines doesn't work with PopenSpawn, so do this instead: self.expect(NL,nonl=True,silent=True) debug_pexpect_msg(self.p) - end = self.p.before + end = self.p.before.rstrip() if not g.debug: vmsg(' ==> {}'.format(cyan(end))) return end