mirror of
https://github.com/aclist/dztui.git
synced 2026-11-12 21:10:37 +01:00
Merge branch 'dzgui7' into chore/test-typehints
This commit is contained in:
54 files changed
+261
-491
No files matched your search
@@ -1,13 +1,12 @@
|
||||
import gi
|
||||
import pytest
|
||||
import subprocess
|
||||
|
||||
from dzgui.const.constants import GIO_SETTINGS_KEY
|
||||
from dzgui.views.mixins.colorscheme import ColorAwareApp
|
||||
|
||||
import gi
|
||||
|
||||
gi.require_version("Gtk", "3.0")
|
||||
from gi.repository import Gtk, Gio, GLib # noqa
|
||||
from gi.repository import Gtk, GLib
|
||||
|
||||
|
||||
class DummyWidget(ColorAwareApp, Gtk.Button): # type: ignore
|
||||
|
||||
@@ -48,5 +48,5 @@ def test_signatures_with_no_ids(monkeypatch, tmp: str, versions: str) -> None:
|
||||
monkeypatch.setattr("dzgui.api.mods.lookup", mock_lookup)
|
||||
dzgui.api.mods.remove_stale_signatures(path, path)
|
||||
with open(tmp, "r") as f:
|
||||
lines = f.readlines()
|
||||
assert lines == ["3410710885,1752864732\n", "3739934289,1780855136\n"]
|
||||
lines = [line.rstrip() for line in f.readlines()]
|
||||
assert lines == ["3410710885,1752864732", "3739934289,1780855136"]
|
||||
@@ -26,6 +26,7 @@ def default_steam_path() -> str:
|
||||
conf = get_config(xdg.config)
|
||||
return str(conf["default_steam_path"])
|
||||
|
||||
# TODO: additional parsing tests
|
||||
|
||||
def test_pefile_length(default_steam_path: str) -> None:
|
||||
try:
|
||||
@@ -45,6 +46,7 @@ def test_invalid_pefile_path() -> None:
|
||||
raise e
|
||||
|
||||
|
||||
# TODO: split into separate test file
|
||||
@pytest.mark.parametrize(
|
||||
"fixture, exception",
|
||||
[
|
||||
|
||||
Reference in new issue
Block a user