2018-01-24 07:03:28 +01:00
|
|
|
Index: patroni/features/environment.py
|
|
|
|
===================================================================
|
|
|
|
--- patroni.orig/features/environment.py
|
|
|
|
+++ patroni/features/environment.py
|
|
|
|
@@ -130,7 +130,7 @@ class PatroniController(AbstractControll
|
|
|
|
if isinstance(self._context.dcs_ctl, KubernetesController):
|
|
|
|
self._context.dcs_ctl.create_pod(self._name[8:], self._scope)
|
|
|
|
os.environ['PATRONI_KUBERNETES_POD_IP'] = '10.0.0.' + self._name[-1]
|
2017-09-15 15:24:01 +02:00
|
|
|
- return subprocess.Popen(['coverage', 'run', '--source=patroni', '-p', 'patroni.py', self._config],
|
|
|
|
+ return subprocess.Popen(['python3-coverage', 'run', '--source=patroni', '-p', 'patroni.py', self._config],
|
|
|
|
stdout=self._log, stderr=subprocess.STDOUT, cwd=self._work_directory)
|
|
|
|
|
|
|
|
def stop(self, kill=False, timeout=15, postgres=False):
|
2018-11-05 08:47:35 +01:00
|
|
|
@@ -802,8 +802,8 @@ def before_all(context):
|
2017-09-15 15:24:01 +02:00
|
|
|
|
|
|
|
def after_all(context):
|
|
|
|
context.dcs_ctl.stop()
|
|
|
|
- subprocess.call(['coverage', 'combine'])
|
|
|
|
- subprocess.call(['coverage', 'report'])
|
|
|
|
+ subprocess.call(['python3-coverage', 'combine'])
|
|
|
|
+ subprocess.call(['python3-coverage', 'report'])
|
|
|
|
|
|
|
|
|
|
|
|
def before_feature(context, feature):
|
2018-01-24 07:03:28 +01:00
|
|
|
Index: patroni/features/steps/patroni_api.py
|
|
|
|
===================================================================
|
|
|
|
--- patroni.orig/features/steps/patroni_api.py
|
|
|
|
+++ patroni/features/steps/patroni_api.py
|
|
|
|
@@ -95,7 +95,7 @@ def do_request(context, request_method,
|
2017-09-15 15:24:01 +02:00
|
|
|
|
|
|
|
@step('I run {cmd}')
|
|
|
|
def do_run(context, cmd):
|
|
|
|
- cmd = ['coverage', 'run', '--source=patroni', '-p'] + shlex.split(cmd)
|
|
|
|
+ cmd = ['python3-coverage', 'run', '--source=patroni', '-p'] + shlex.split(cmd)
|
|
|
|
try:
|
|
|
|
# XXX: Dirty hack! We need to take name/passwd from the config!
|
|
|
|
env = os.environ.copy()
|