diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2019-12-23 07:52:24 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2019-12-23 07:52:24 +0300 |
commit | d10c1d977205dd5a2f1b227cb943b393a3a4184f (patch) | |
tree | 138d812237e7553bc4c26bc89c37dc0d10f6b5a2 /test/toolkit.py | |
parent | update cmake-common (diff) | |
download | aes-tools-d10c1d977205dd5a2f1b227cb943b393a3a4184f.tar.gz aes-tools-d10c1d977205dd5a2f1b227cb943b393a3a4184f.zip |
test: pylint/pep8 fixes
Diffstat (limited to '')
-rw-r--r-- | test/toolkit.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/test/toolkit.py b/test/toolkit.py index f8a74ba..4abdbf4 100644 --- a/test/toolkit.py +++ b/test/toolkit.py @@ -9,6 +9,7 @@ import logging import os.path import subprocess + class Algorithm(Enum): @staticmethod def parse(s): @@ -50,6 +51,7 @@ class Mode(Enum): def __str__(self): return self.value + class BlockInput: def __init__(self, key, plaintexts, iv=None): self.key = key @@ -63,6 +65,7 @@ class BlockInput: args.extend(self.plaintexts) return args + class Tools: def __init__(self, search_dirs, use_sde=False): if search_dirs: @@ -82,14 +85,14 @@ class Tools: def run(self, tool_path, args): cmd_list = ['sde', '--', tool_path] if self._use_sde else [tool_path] cmd_list.extend(args) - logging.info('Trying to execute: ' + subprocess.list2cmdline(cmd_list)) + logging.info('Trying to execute: %s', subprocess.list2cmdline(cmd_list)) try: output = subprocess.check_output( cmd_list, universal_newlines=True, stderr=subprocess.STDOUT) except subprocess.CalledProcessError as e: - logging.error('Output:\n' + e.output) + logging.error('Output:\n%s', e.output) raise - logging.info('Output:\n' + output) + logging.info('Output:\n%s', output) return output.split() @staticmethod |