Rename the Python package to daynivo_kiosk
src/voxip_kiosk -> src/daynivo_kiosk, with every import, the launchers, install.sh, the Makefile and the manager's gunicorn app path. An upgrade replaces /usr/lib/voxip-kiosk/python as a whole, so the old package disappears; tested by upgrading an installation of the previous commit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
d0f3206ff4
commit
6733aacb6e
62 files changed
+43
-43
No files matched your search
+5
-5
@@ -4,7 +4,7 @@ from pathlib import Path
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk.paths import Paths
|
||||
from daynivo_kiosk.paths import Paths
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
|
||||
@@ -39,7 +39,7 @@ class FakeHelper:
|
||||
self.responses = {}
|
||||
|
||||
def call(self, verb, *args, payload=None, timeout=60):
|
||||
from voxip_kiosk.helper_client import HelperError
|
||||
from daynivo_kiosk.helper_client import HelperError
|
||||
|
||||
self.calls.append((verb, args, payload))
|
||||
if self.fail:
|
||||
@@ -53,7 +53,7 @@ class FakeCDP:
|
||||
self.fail = None
|
||||
|
||||
def _do(self, name, *args):
|
||||
from voxip_kiosk.cdp import CDPError
|
||||
from daynivo_kiosk.cdp import CDPError
|
||||
|
||||
self.calls.append((name, args))
|
||||
if self.fail:
|
||||
@@ -80,7 +80,7 @@ def fake_cdp():
|
||||
@pytest.fixture
|
||||
def quiet_system(monkeypatch):
|
||||
"""Keep the web tests independent of the machine they run on."""
|
||||
from voxip_kiosk import netinfo, services, sysinfo
|
||||
from daynivo_kiosk import netinfo, services, sysinfo
|
||||
|
||||
monkeypatch.setattr(services, "summary", lambda: {
|
||||
"browser": {"unit": services.BROWSER_UNIT, "status": "ok", "label": "Actief", "restarts": "2", "since": ""},
|
||||
@@ -106,7 +106,7 @@ def quiet_system(monkeypatch):
|
||||
|
||||
@pytest.fixture
|
||||
def app(paths, fake_helper, fake_cdp, quiet_system):
|
||||
from voxip_kiosk.web import create_app
|
||||
from daynivo_kiosk.web import create_app
|
||||
|
||||
application = create_app(paths, helper=fake_helper, cdp=fake_cdp)
|
||||
application.config["TESTING"] = True
|
||||
|
||||
+3
-3
@@ -2,9 +2,9 @@ import json
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk.agent import Agent, HUNG_RELOAD_AFTER, HUNG_RESTART_AFTER
|
||||
from voxip_kiosk.cdp import CDPError
|
||||
from voxip_kiosk.config import save_config
|
||||
from daynivo_kiosk.agent import Agent, HUNG_RELOAD_AFTER, HUNG_RESTART_AFTER
|
||||
from daynivo_kiosk.cdp import CDPError
|
||||
from daynivo_kiosk.config import save_config
|
||||
|
||||
|
||||
class Clock:
|
||||
|
||||
@@ -2,8 +2,8 @@ import json
|
||||
from pathlib import Path
|
||||
from urllib.parse import parse_qs, urlsplit
|
||||
|
||||
from voxip_kiosk import browser as b
|
||||
from voxip_kiosk.config import DEFAULTS
|
||||
from daynivo_kiosk import browser as b
|
||||
from daynivo_kiosk.config import DEFAULTS
|
||||
|
||||
XRANDR = """Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 7680 x 7680
|
||||
HDMI-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 531mm x 299mm
|
||||
|
||||
@@ -4,7 +4,7 @@ import stat
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import config as c
|
||||
from daynivo_kiosk import config as c
|
||||
|
||||
|
||||
def test_default_file_matches_defaults(paths):
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import services
|
||||
from voxip_kiosk.cdp import CDPError
|
||||
from voxip_kiosk.config import save_config
|
||||
from voxip_kiosk.healthcheck import CDP_FAILURES_BEFORE_RESTART, DISPLAY_RETRY_AFTER, HealthCheck
|
||||
from daynivo_kiosk import services
|
||||
from daynivo_kiosk.cdp import CDPError
|
||||
from daynivo_kiosk.config import save_config
|
||||
from daynivo_kiosk.healthcheck import CDP_FAILURES_BEFORE_RESTART, DISPLAY_RETRY_AFTER, HealthCheck
|
||||
|
||||
|
||||
class World:
|
||||
|
||||
@@ -3,8 +3,8 @@ import subprocess
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import helper as h
|
||||
from voxip_kiosk.config import load_config
|
||||
from daynivo_kiosk import helper as h
|
||||
from daynivo_kiosk.config import load_config
|
||||
|
||||
|
||||
class Recorder:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import netconfig as n
|
||||
from voxip_kiosk.validation import ValidationError
|
||||
from daynivo_kiosk import netconfig as n
|
||||
from daynivo_kiosk.validation import ValidationError
|
||||
|
||||
|
||||
def test_validate_static_ethernet():
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
from voxip_kiosk import services, sysinfo
|
||||
from daynivo_kiosk import services, sysinfo
|
||||
|
||||
|
||||
def test_parse_throttled():
|
||||
|
||||
@@ -6,8 +6,8 @@ import tarfile
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import updater as u
|
||||
from voxip_kiosk.config import save_config
|
||||
from daynivo_kiosk import updater as u
|
||||
from daynivo_kiosk.config import save_config
|
||||
|
||||
API = u.RELEASE_API
|
||||
BASE = "https://git.example.nl/rothman/daynivo-kiosk-os/releases/download"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk import validation as v
|
||||
from daynivo_kiosk import validation as v
|
||||
|
||||
|
||||
@pytest.mark.parametrize("url", [
|
||||
|
||||
+5
-5
@@ -2,8 +2,8 @@ import json
|
||||
|
||||
import pytest
|
||||
|
||||
from voxip_kiosk.config import load_config
|
||||
from voxip_kiosk.web import auth
|
||||
from daynivo_kiosk.config import load_config
|
||||
from daynivo_kiosk.web import auth
|
||||
|
||||
from .conftest import PASSWORD, csrf_from, token
|
||||
|
||||
@@ -113,7 +113,7 @@ def test_password_change_invalidates_other_sessions(app, logged_in):
|
||||
|
||||
|
||||
def test_idle_session_expires(app, logged_in, monkeypatch):
|
||||
from voxip_kiosk.web import views
|
||||
from daynivo_kiosk.web import views
|
||||
|
||||
real = views.time.time
|
||||
monkeypatch.setattr(views.time, "time", lambda: real() + views.IDLE_TIMEOUT + 5)
|
||||
@@ -141,7 +141,7 @@ def test_public_clients_blocked(client, addr, allowed):
|
||||
|
||||
|
||||
def test_same_subnet_global_ipv6_allowed():
|
||||
from voxip_kiosk.web.security import client_allowed
|
||||
from daynivo_kiosk.web.security import client_allowed
|
||||
|
||||
assert client_allowed("2a02:a210:1:2::99", False, ["2a02:a210:1:2::5/64"])
|
||||
assert not client_allowed("2a02:a210:9:9::99", False, ["2a02:a210:1:2::5/64"])
|
||||
@@ -180,7 +180,7 @@ def test_pages_render(logged_in, path):
|
||||
|
||||
|
||||
def test_dashboard_masks_token(logged_in, paths):
|
||||
from voxip_kiosk.config import save_config
|
||||
from daynivo_kiosk.config import save_config
|
||||
|
||||
save_config(paths.config_file, {"url": "https://portal.example.nl/display/hal?token=supergeheimtoken99"})
|
||||
body = logged_in.get("/").get_data(as_text=True)
|
||||
|
||||
Reference in new issue
Block a user