diff options
author | Petr Viktorin <pviktori@redhat.com> | 2013-06-25 12:29:25 +0200 |
---|---|---|
committer | Petr Viktorin <pviktori@redhat.com> | 2013-07-15 15:49:14 +0200 |
commit | c47f3154be16a096b2d255c654e2277954b14833 (patch) | |
tree | 8476fce00eabfd52576acde8d3ec899aea6dbd15 /ipatests/test_integration/host.py | |
parent | 19a0d51d89b640c04dc285067fc59b4a7fe9ca7f (diff) | |
download | freeipa-c47f3154be16a096b2d255c654e2277954b14833.tar.gz freeipa-c47f3154be16a096b2d255c654e2277954b14833.tar.xz freeipa-c47f3154be16a096b2d255c654e2277954b14833.zip |
Make BeakerLib logging less verbose
Logs from Beaker jobs are normally very brief, with the standard
output/error containing detailed information. Make ipa-run-tests
with BeakerLib plugin follow this convention.
Only include INFO and higher level messages in the Beaker logs.
Downgrade several message levels to DEBUG.
Log to console using Python logging instead of showing the Beaker logs.
Since ipa-run-tests sets up its own logging, Nose's own log
handling just causes duplicate messages. Disable it with --nologcapture.
Diffstat (limited to 'ipatests/test_integration/host.py')
-rw-r--r-- | ipatests/test_integration/host.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ipatests/test_integration/host.py b/ipatests/test_integration/host.py index 8109f51aa..9accdf035 100644 --- a/ipatests/test_integration/host.py +++ b/ipatests/test_integration/host.py @@ -99,7 +99,7 @@ class RemoteCommand(object): self.log.error('Exit code: %s', self.returncode) raise subprocess.CalledProcessError(self.returncode, self.argv) else: - self.log.info('Exit code: %s', self.returncode) + self.log.debug('Exit code: %s', self.returncode) return self.returncode def _start_pipe_thread(self, result_list, stream, name, do_log=True): @@ -108,7 +108,7 @@ class RemoteCommand(object): def read_stream(): for line in stream: if do_log: - log.info(line.rstrip('\n')) + log.debug(line.rstrip('\n')) result_list.append(line) thread = threading.Thread(target=read_stream) @@ -285,7 +285,7 @@ class Host(object): def get_file_contents(self, filename): """Read the named remote file and return the contents as a string""" - self.log.info('READ %s', filename) + self.log.debug('READ %s', filename) with self.sftp.open(filename) as f: return f.read() @@ -297,7 +297,7 @@ class Host(object): def file_exists(self, filename): """Return true if the named remote file exists""" - self.log.info('STAT %s', filename) + self.log.debug('STAT %s', filename) try: self.sftp.stat(filename) except IOError, e: @@ -308,7 +308,7 @@ class Host(object): return True def get_file(self, remotepath, localpath): - self.log.info('GET %s', remotepath) + self.log.debug('GET %s', remotepath) self.sftp.get(remotepath, localpath) def put_file(self, localpath, remotepath): |