mirror of
https://github.com/infiniteCable2/openpilot.git
synced 2026-09-30 11:33:41 +08:00
more ty, part 2 (#38379)
This commit is contained in:
@@ -63,10 +63,10 @@ class UploaderTestCase:
|
||||
seg_dir: str
|
||||
|
||||
def set_ignore(self):
|
||||
uploader.Api = MockApiIgnore
|
||||
uploader.Api = MockApiIgnore # ty: ignore[invalid-assignment] # test double
|
||||
|
||||
def setup_method(self):
|
||||
uploader.Api = MockApi
|
||||
uploader.Api = MockApi # ty: ignore[invalid-assignment] # test double
|
||||
uploader.fake_upload = True
|
||||
uploader.force_wifi = True
|
||||
uploader.allow_sleep = False
|
||||
|
||||
@@ -19,7 +19,7 @@ class TestDeleter(UploaderTestCase):
|
||||
self.f_type = "fcamera.hevc"
|
||||
super().setup_method()
|
||||
self.fake_stats = Stats(f_bavail=0, f_blocks=10, f_frsize=4096)
|
||||
deleter.os.statvfs = self.fake_statvfs
|
||||
deleter.os.statvfs = self.fake_statvfs # ty: ignore[invalid-assignment] # test double
|
||||
|
||||
def start_thread(self):
|
||||
self.end_event = threading.Event()
|
||||
|
||||
@@ -5,6 +5,7 @@ import random
|
||||
import string
|
||||
import subprocess
|
||||
import time
|
||||
from collections.abc import Collection
|
||||
from collections import defaultdict
|
||||
from pathlib import Path
|
||||
import pytest
|
||||
@@ -74,8 +75,8 @@ class TestLoggerd:
|
||||
end_type = SentinelType.endOfRoute if route else SentinelType.endOfSegment
|
||||
assert msgs[-1].sentinel.type == end_type
|
||||
|
||||
def _publish_random_messages(self, services: list[str]) -> dict[str, list]:
|
||||
pm = messaging.PubMaster(services)
|
||||
def _publish_random_messages(self, services: Collection[str]) -> dict[str, list]:
|
||||
pm = messaging.PubMaster(list(services))
|
||||
|
||||
managed_processes["loggerd"].start()
|
||||
for s in services:
|
||||
|
||||
Reference in New Issue
Block a user