Commit Graph
2 Commits
Author SHA1 Message Date
Khem Raj 1a442c230b python3-glances: fix ptest args being consumed by GlancesMain's argv slicing
tests/test_core.py does GlancesMain(args_begin_at=2) at module import
time, slicing the real process sys.argv. Passing --automake on the
pytest command line (rather than via PYTEST_ADDOPTS) shifted that
slice and broke it; set it via PYTEST_ADDOPTS instead.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2026-08-16 16:21:50 -07:00
Trevor Gamblin 2592ce3ad8 python3-glances: add ptest
Example output:

|root@qemux86-64:~# ptest-runner python3-glances
|START: ptest-runner
|2026-08-14T13:48
|BEGIN: /usr/lib/python3-glances/ptest
|============================= test session starts ==============================
|platform linux -- Python 3.14.7, pytest-9.1.1, pluggy-1.6.0
|rootdir: /usr/lib/python3-glances/ptest
|plugins: putao-0.4, anyio-4.14.2, inline-snapshot-0.35.3
|collected 37 items
|
|tests/test_core.py .....................................                 [100%]
|
|============================== 37 passed in 8.02s ==============================
|DURATION: 8
|END: /usr/lib/python3-glances/ptest
|2026-08-14T13:48
|STOP: ptest-runner
|TOTAL: 1 FAIL: 0
|root@qemux86-64:~#

Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com>
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
2026-08-14 14:38:24 -07:00