Commit Graph

36 Commits

Author SHA1 Message Date
cl0cks4fe
dd9d5d4528 Unittest to pytest (#32366)
* add pytest-asyncio

* switch common

* switch selfdrive

* switch system

* switch tools

* small fixes

* fix setUp and valgrind pytest

* switch to setup

* fix random

* switch mock

* switch test_lateral_limits

* revert test_ui

* fix poetry.lock

* add unittest to banned-api

* add inline ignores to remaining unittest imports

* revert test_models

* revert check_can_parser_performance

* one more skip

---------

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2024-05-17 11:01:44 -07:00
YassineYousfi
754dd45ffa disable navigate on openpilot (#32106)
* 2eedcd90-b7db-46cb-86be-740f48ded7ab/700

* noop ciao

* here too

* mapsd too

* update translations

* disable mapsd test from test onroad

* disable mapRenderState test from timings

* lint

* fix exp mode toggle panel

* update tr

* french done

* dont build mapd

* only no nav

* just comment

* deprecate nav fields

* rm not comment

* dont deprecate too much

* remove from services

* merge cereal
2024-04-09 10:40:38 -07:00
Justin Newberry
69982d43cd move casync release creation to use a tarball of files (#32089)
* tar archive instead

* fix

* move this here

* migrate these

* fix this

* update readme

* fix that

* try to build nightly

* Revert "try to build nightly"

This reverts commit 4ea680cb6a1f985c0490168724c99bcb45af9899.

* caexclude is no longer required

* finish up

* sorted

* need this

* and that

* context mnager

* path based
2024-04-05 11:00:45 -07:00
Justin Newberry
19db56b1f6 tici tests: remove pytest.main (#31622)
pytest.main is bad!
2024-02-27 14:06:18 -08:00
Cameron Clough
995250ae49 use pyupgrade to update to new typing syntax (#31580)
* add pyupgrade hook

* run pyupgrade (pre-commit run -a)

* ruff --fix

* Revert "add pyupgrade hook"

This reverts commit 56ec18bb6b8602a0b612f3803d96cdad14b52066.

* revert changes to third_party/

* manual type fixes

* explicit Optional wrapping capnp objects
2024-02-24 16:41:23 -08:00
Justin Newberry
70288d1742 test_power_draw: combine mapsd and navmodeld (#31375)
* combine

* combine

* combine

* simpler

* nounion
2024-02-08 11:31:55 -08:00
Justin Newberry
caa9dff610 test_power_draw: wait for power instead of fixed warmup time (#31318)
* wait for valid

* reuuse that

* assert warmup

* Wip

* fix that

* reset

* none

* timeout

* maxlen

* consecutive

* proc

* fix

* local

* same as before

* mean

* fixes

* SA

* this is the real warmup time

* this is the real warmup time

* Cleanup

* Cleanup

* monotonic + len

* reduce duplication

* fix

* fix

---------

Co-authored-by: Comma Device <device@comma.ai>
2024-02-07 13:54:46 -08:00
Justin Newberry
0277fc5548 Pytest: consistent hardware state for tici tests (#31279)
* consistent hardware

* consistent hardware

* moved

* this too

* ruff

* s

* duplicated

---------

Co-authored-by: Comma Device <device@comma.ai>
2024-02-02 14:18:01 -08:00
Justin Newberry
086c509fde Create message mocking tools (#31249)
* add mocking tools

* fix map renderer

* use for power draw

* fix those

* whitespace

* rename to services

* fix the rate

* remove
2024-01-31 18:47:49 -08:00
Harald Schäfer
e6c97c3846 Delete lat planner (#31089)
* Initial commit

* Fixup

* typo

* ignore lateral plan

* Update cereal

* Remove lateralPlan

* Fix release build

* Fix release build

* give car params

* Add carParams to include_all_types

* Write car param in powerdraw test

* add demo mode

* Update model regf

* proc replay ref commit

* Try

* Move enum definition

* Update cereal

* typo

* Write car param for modeld test

* Update ref

* Update model ref again

---------

Co-authored-by: Kacper Rączy <gfw.kra@gmail.com>
2024-01-21 12:09:48 -08:00
Adeeb Shihadeh
e0d0896dcf test_power_draw: check msgs expect first for cleaner error 2024-01-20 17:20:21 -08:00
Justin Newberry
aec7cea30d Pytest: tici mark for skipping on-device tests (#30412)
* mark tici

* not those ones

* missed that one

* add those

* add pypoetry

* oops
2023-11-07 17:35:44 -08:00
Harald Schäfer
11855eab5d power draw test: improve verbosity (#30402)
* improve verbosity

* unused import
2023-11-07 08:39:23 -08:00
Adeeb Shihadeh
7bee13e2d1 raise gpu clock (#30358)
* raise gpu clock

* update modeld power draw
2023-11-01 14:48:49 -07:00
YassineYousfi
cad17b1255 modeld: parsing and publishing in python (#30273)
* WIP try modeld all in python

* fix plan

* add lane lines stds

* fix lane lines prob

* add lead prob

* add meta

* simplify plan parsing

* add hard brake pred

* add confidence

* fix desire state and desire pred

* check this file for now

* rm prints

* rm debug

* add todos

* add plan_t_idxs

* same as cpp

* removed cython

* add wfd width - rm cpp code

* add new files rm old files

* get metadata at compile time

* forgot this file

* now uses more CPU

* not used

* update readme

* lint

* copy this too

* simplify disengage probs

* update model replay ref commit

* update again

* confidence: remove if statemens

* use publish_state.enqueue

* Revert "use publish_state.enqueue"

This reverts commit d8807c8348338a1f773a8de00fd796abb8181404.

* confidence: better shape defs

* use ModelConstants class

* fix confidence

* Parser

* slightly more power too

* no inline ifs :(

* confidence: just use if statements
2023-10-19 14:23:51 -07:00
Shane Smiskol
7f073483bb services: capitalize constant service list (#30005)
* rename

* bump

* Apply suggestions from code review
2023-09-21 18:25:15 -07:00
Adeeb Shihadeh
a9626f95b6 add openpilot prefix to imports (#29498)
* add openpilot prefix to imports

* more

* more

* fix docs

* fix linter

* bump submodules

* fix patched tests

* update dynamic imports

* debug

* Revert "debug"

This reverts commit db5e13b9911cc74438bee123bc3430da6c31b24b.

* fix pm test
2023-08-20 20:49:55 -07:00
Adeeb Shihadeh
09ffce8073 add small ui for jenkins runners (#29382) 2023-08-13 18:01:51 -07:00
Justin Newberry
e4ead4f183 Ruff: b905 (strict zip) (#29336)
* added mutable default args

* most of the Bs

* add comment about lrucache

* b905
2023-08-11 16:13:51 -07:00
Adeeb Shihadeh
e3ca9f3e85 tici: reset panda state in amp test setup (#29237) 2023-08-04 15:07:01 -07:00
Adeeb Shihadeh
ed07c3ceda tici: better cleanup in amp test (#29146) 2023-07-25 21:41:31 -07:00
Adeeb Shihadeh
d92c9aef23 tici: speedup power save setting (#29100)
* speedup

* update type

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-22 17:15:58 -07:00
Adeeb Shihadeh
e2b5d1e29a mapsd: rendering tests (#28981)
* mapsd: rendering tests

* run

* speedup
2023-07-16 14:39:34 -07:00
Adeeb Shihadeh
7d6c22949a tici: improve amp test (#28648) 2023-06-22 20:57:36 -07:00
Comma Device
dec3c5a57d test_amp: wait for panda 2023-06-09 15:36:41 -07:00
Mitchell Goff
729d3ddcb5 Check msg count in test_power_draw (#28444)
* Check msg count in test_power_draw.

* Use drain_sock

* Bug fix

* Combine into a single table

* Check camera state msgs and no default value for Proc.msgs

* Update system/hardware/tici/tests/test_power_draw.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

---------

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2023-06-07 14:06:11 -07:00
mitchellgoffpc
ae0768909b Lowered expected power draw for mapsd 2023-06-06 11:58:32 -07:00
Mitchell Goff
dd6f7116f7 Test power usage for mapsd and navmodeld (#28378)
* Test power usage for mapsd and navmodeld

* Send LLK message from thread

* Use threading.Event
2023-06-05 20:27:02 -07:00
Robbe Derks
21bcd7db63 Dynamic device type (#28011)
* tizi_device_type

* fix test

* also change it in the C versin
2023-05-04 12:12:01 +02:00
Adeeb Shihadeh
d5a0a4b3e8 Jenkins tuneup (#28095)
* tuneup

* use service messages

* logmono

* not passive
2023-05-03 16:52:20 -07:00
Adeeb Shihadeh
767ed4295f tizi: retry amp comms (#27735)
* tizi: retry amp comms

* ensure all config is written together

* simple test

* check errors

* test shutdown

* a tici exclusive

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-04-06 23:38:16 -07:00
Adeeb Shihadeh
9eda72d871 update manifest path in test 2023-04-05 22:39:57 -07:00
Adeeb Shihadeh
39a1a917e7 tici: move tests to tests/ 2023-04-05 22:17:57 -07:00
Adeeb Shihadeh
c6b749fb96 add pyside2 package (#25602) 2022-08-30 15:10:52 -07:00
Willem Melching
753f4c7fab casync unittests (#25306)
* simple extract test

* add test with loopback

* test for chunk reuse

* test seeding

* add instructions

* cleanup

* install casync

* make more tests work without a loopback
2022-07-29 17:46:19 +02:00
Willem Melching
205f6f7414 casync: manifest compare script (#25129)
* casync compare script

* typo

* cleanup output
2022-07-12 16:09:21 +02:00