Commit 931391fc authored by ∞'s avatar 💻

QA

parent 624bcfd1
Pipeline #1791 failed with stages
in 16 seconds
......@@ -8,14 +8,12 @@ import copy
import collections
import importlib
import inspect
import io
import os
import pprint
import re
import sys
import textwrap
import types
import shlex
import subprocess
import colorama
......@@ -82,8 +80,8 @@ def autotest(path, cmd, ignore=None):
'auth.User'
)
"""
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE,
stderr=subprocess.PIPE, shell=True)
proc = subprocess.Popen(
cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
test_out, test_err = proc.communicate()
fixture = b'\n'.join([
......
import os
import sys
from io import TextIOWrapper, BytesIO
import cli2
def save_result(self, result):
self.__dict__.setdefault('_result', [])
self._results.append(result)
def patch(console_script, result_handler):
console_script.handle_result = result_handler.__get__(
console_script,
type(console_script)
)
def test_help():
cli2.autotest('tests/cli2_help.txt', 'cli2', 'help')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment