mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-10 20:02:13 +08:00
d7c0906d0b
* fast * fix * same ratio * output * check old * error * fail * better * log * test faster runner * work? * test * ratio * forward * try without wait * test old distance * fxi * test old runner * test this * assert distance * cleanup * better * get distance * cleanup * choose runner * very slow * wait * put this back
20 lines
753 B
Python
20 lines
753 B
Python
import pytest
|
|
import warnings
|
|
|
|
# Since metadrive depends on pkg_resources, and pkg_resources is deprecated as an API
|
|
warnings.filterwarnings("ignore", category=DeprecationWarning)
|
|
|
|
from openpilot.tools.sim.bridge.metadrive.metadrive_bridge import MetaDriveBridge
|
|
from openpilot.tools.sim.tests.test_sim_bridge import TestSimBridgeBase
|
|
|
|
@pytest.mark.slow
|
|
@pytest.mark.filterwarnings("ignore::pyopencl.CompilerWarning") # Unimportant warning of non-empty compile log
|
|
class TestMetaDriveBridge(TestSimBridgeBase):
|
|
@pytest.fixture(autouse=True)
|
|
def setup_create_bridge(self):
|
|
self.test_duration = 15
|
|
self.minimal_distance = 10
|
|
|
|
def create_bridge(self):
|
|
return MetaDriveBridge(False, False, self.test_duration, self.minimal_distance, True)
|