def pytest_report_header(config, startdir): summary = [] t = tempfile.mktemp() try: ac = Account(t, eventlogging=False) info = ac.get_info() ac.shutdown() finally: os.remove(t) summary.extend([ 'Deltachat core={} sqlite={}'.format( info['deltachat_core_version'], info['sqlite_version'], ) ]) cfg = config.option.liveconfig if cfg: if "#" in cfg: url, token = cfg.split("#", 1) summary.append( 'Liveconfig provider: {}#<token ommitted>'.format(url)) else: summary.append('Liveconfig file: {}'.format(cfg)) return summary
def pytest_report_header(config, startdir): summary = [] t = tempfile.mktemp() m = MonkeyPatch() try: m.setattr(sys.stdout, "write", lambda x: len(x)) ac = Account(t) info = ac.get_info() ac.shutdown() finally: m.undo() os.remove(t) summary.extend([ 'Deltachat core={} sqlite={}'.format( info['deltachat_core_version'], info['sqlite_version'], ) ]) cfg = config.option.liveconfig if cfg: if "#" in cfg: url, token = cfg.split("#", 1) summary.append( 'Liveconfig provider: {}#<token ommitted>'.format(url)) else: summary.append('Liveconfig file: {}'.format(cfg)) return summary
def pytest_report_header(config, startdir): t = tempfile.mktemp() try: ac = Account(t) info = ac.get_info() del ac finally: os.remove(t) return "Deltachat core={} sqlite={}".format( info['deltachat_core_version'], info['sqlite_version'], )
def pytest_report_header(config, startdir): t = tempfile.mktemp() try: ac = Account(t) info = ac.get_info() del ac finally: os.remove(t) return "Deltachat core={} rpgp={} openssl={} sqlite={}".format( info["deltachat_core_version"], info["rpgp_enabled"], info['openssl_version'], info['sqlite_version'], )