Continuing enforcement of line length and simplifying date conversions

This commit is contained in:
Nex
2022-08-13 02:14:24 +02:00
parent 0f503f72b5
commit 271fe5fbee
60 changed files with 457 additions and 310 deletions

View File

@@ -4,7 +4,6 @@
# https://license.mvt.re/1.1/
import io
import logging
import os
import tarfile
@@ -19,7 +18,7 @@ class TestBackupModule:
def test_module_folder(self):
backup_path = get_android_backup_folder()
mod = SMS(target_path=backup_path, log=logging)
mod = SMS(target_path=backup_path)
files = []
for root, subdirs, subfiles in os.walk(os.path.abspath(backup_path)):
for fname in subfiles:
@@ -32,7 +31,7 @@ class TestBackupModule:
def test_module_file(self):
fpath = os.path.join(get_android_backup_folder(), "backup.ab")
mod = SMS(target_path=fpath, log=logging)
mod = SMS(target_path=fpath)
with open(fpath, "rb") as f:
data = f.read()
tardata = parse_backup_file(data)
@@ -48,7 +47,7 @@ class TestBackupModule:
def test_module_file2(self):
fpath = os.path.join(get_android_backup_folder(), "backup2.ab")
mod = SMS(target_path=fpath, log=logging)
mod = SMS(target_path=fpath)
with open(fpath, "rb") as f:
data = f.read()
tardata = parse_backup_file(data, password="123456")
@@ -64,7 +63,7 @@ class TestBackupModule:
def test_module_file3(self):
fpath = os.path.join(get_android_backup_folder(), "backup3.ab")
mod = SMS(target_path=fpath, log=logging)
mod = SMS(target_path=fpath)
with open(fpath, "rb") as f:
data = f.read()
tardata = parse_backup_file(data)