summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorJhon Honce <jhonce@redhat.com>2018-10-15 11:28:56 -0700
committerJhon Honce <jhonce@redhat.com>2018-10-23 07:58:48 -0700
commita7ea7e9d5c9b1d023fc57f4c5da5faeece187bf7 (patch)
tree36d48c917dc9ffe169b709de9e105a9b6144c5a0 /contrib
parent2e6bc3c7af261228ae7a75cb5749062928fa24b3 (diff)
downloadpodman-a7ea7e9d5c9b1d023fc57f4c5da5faeece187bf7.tar.gz
podman-a7ea7e9d5c9b1d023fc57f4c5da5faeece187bf7.tar.bz2
podman-a7ea7e9d5c9b1d023fc57f4c5da5faeece187bf7.zip
Downgrade code to support python3.4
* Added tox configuration to test python 3.4, 3.5 and 3.6. Tox testing not enabled on every PR * Updated MANIFEST.ini to support tox * Correct comments Fixes #1641 Signed-off-by: Jhon Honce <jhonce@redhat.com>
Diffstat (limited to 'contrib')
-rw-r--r--contrib/python/podman/MANIFEST.in1
-rw-r--r--contrib/python/podman/tox.ini8
-rw-r--r--contrib/python/pypodman/pypodman/lib/actions/pod/processes_parser.py4
-rw-r--r--contrib/python/pypodman/pypodman/lib/podman_parser.py4
4 files changed, 13 insertions, 4 deletions
diff --git a/contrib/python/podman/MANIFEST.in b/contrib/python/podman/MANIFEST.in
index 72e638cb9..a5897de50 100644
--- a/contrib/python/podman/MANIFEST.in
+++ b/contrib/python/podman/MANIFEST.in
@@ -1,2 +1,3 @@
prune test/
include README.md
+include requirements.txt
diff --git a/contrib/python/podman/tox.ini b/contrib/python/podman/tox.ini
new file mode 100644
index 000000000..797eafbe3
--- /dev/null
+++ b/contrib/python/podman/tox.ini
@@ -0,0 +1,8 @@
+[tox]
+envlist = py34,py35,py36
+skipdist = True
+
+[testenv]
+deps=-rrequirements.txt
+whitelist_externals = bash
+commands=bash test/test_runner.sh
diff --git a/contrib/python/pypodman/pypodman/lib/actions/pod/processes_parser.py b/contrib/python/pypodman/pypodman/lib/actions/pod/processes_parser.py
index 411a6d5a3..ecfcb883a 100644
--- a/contrib/python/pypodman/pypodman/lib/actions/pod/processes_parser.py
+++ b/contrib/python/pypodman/pypodman/lib/actions/pod/processes_parser.py
@@ -10,7 +10,7 @@ class ProcessesPod(AbstractActionBase):
@classmethod
def subparser(cls, parent):
- """Add Images command to parent parser."""
+ """Add Pod Ps command to parent parser."""
parser = parent.add_parser('ps', help='list processes of pod')
super().subparser(parser)
@@ -40,7 +40,7 @@ class ProcessesPod(AbstractActionBase):
parser.set_defaults(class_=cls, method='processes')
def __init__(self, args):
- """Contstruct ProcessesPod class."""
+ """Construct ProcessesPod class."""
if args.sort == 'created':
args.sort = 'createdat'
elif args.sort == 'count':
diff --git a/contrib/python/pypodman/pypodman/lib/podman_parser.py b/contrib/python/pypodman/pypodman/lib/podman_parser.py
index 1ba9bb7fc..d3c84224f 100644
--- a/contrib/python/pypodman/pypodman/lib/podman_parser.py
+++ b/contrib/python/pypodman/pypodman/lib/podman_parser.py
@@ -154,7 +154,7 @@ class PodmanArgumentParser(argparse.ArgumentParser):
getattr(args, 'run_dir')
or os.environ.get('RUN_DIR')
or config['default'].get('run_dir')
- or Path(args.xdg_runtime_dir, 'pypodman')
+ or str(Path(args.xdg_runtime_dir, 'pypodman'))
) # yapf: disable
setattr(
@@ -211,7 +211,7 @@ class PodmanArgumentParser(argparse.ArgumentParser):
args.identity_file = None
if args.host:
- args.local_socket_path = Path(args.run_dir, 'podman.socket')
+ args.local_socket_path = str(Path(args.run_dir, 'podman.socket'))
else:
args.local_socket_path = args.remote_socket_path