pytest-embedded-idf
A pytest-embedded service tailored for ESP-IDF applications and test workflows.
Service Activation
Activate this service by passing idf to --embedded-services. Typically used together with esp for physical hardware testing:
pytest --embedded-services esp,idf --app-path /path/to/esp-idf-app
Extra Functionalities
- App Metadata Parsing: Reads
project_description.jsonand build artifacts to identify the target chip, flash settings, partition tables, and binary paths. - Smart Flashing & Caching: Automatically flashes the bootloader, partition table, and application. Caches binary hashes across the session to skip redundant flashing.
- Panic & Core Dump Decoding: Automatically parses and decodes panic stack traces and core dumps from target flash/UART when a test fails.
- Partition Table & NVS Controls: Erase NVS blocks or customize the partition tool script.
- Unity Test Runner: Integrated support for Unity C test suites via
dut.expect_unity_test_output()and thecase_testerfixture for test menu navigation. - Linux Target Support: Includes
LinuxDutandLinuxSerialto test ESP-IDF POSIX/Linux applications directly on the host machine. - Dynamic Parametrization: Provides
idf_parametrizeto expandsupported_targetsand filter chips by SoC capability strings.
CLI Options
--supported-targets: Comma-separated list of officially supported targets for the test. Default:None.--preview-targets: Comma-separated list of preview/experimental targets for the test. Default:None.--part-tool: Path to the partition table generator script. Default:$IDF_PATH/components/partition_table/gen_esp32part.py.--confirm-target-elf-sha256: Verify ELF SHA256 against target flash before skipping re-flashing. Default:False.--erase-nvs: Erase NVS partition blocks when flashing binaries. Default:False.--skip-check-coredump: Skip auto-checking for core dumps and panic traces on test failure. Default:False.
Quick Example
from pytest_embedded import Dut
def test_idf_app(dut: Dut):
# App information is parsed automatically from the ESP-IDF build directory
print(f'Running target: {dut.app.target}')
dut.expect('Booting ESP-IDF app...')
dut.expect('Hello world!')
Metadata
Release files for pytest-embedded-idf 2.10.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pytest_embedded_idf-2.10.2.tar.gz | 26.8 kB | Without provenance | Details for pytest_embedded_idf-2.10.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pytest_embedded_idf-2.10.2-py3-none-any.whl | Python 3 | none | any | Details for pytest_embedded_idf-2.10.2-py3-none-any.whl |
Total release size: 50.3 kB
Release files / pytest_embedded_idf-2.10.2.tar.gz
| Download URL | pytest_embedded_idf-2.10.2.tar.gz |
|---|---|
| Size | 26.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
795bb7f5e8f3a7fd610b16ff16cf7f6e0e6b60cfa824bf3b769c60042d690535
|
|
BLAKE2b-256 checksum How to use checksums |
6a0f023a148073c53e5aa3623e22786e69efb80101b4ab356fcbabf7fe928965
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.31.0
|
Release files / pytest_embedded_idf-2.10.2-py3-none-any.whl
| Download URL | pytest_embedded_idf-2.10.2-py3-none-any.whl |
|---|---|
| Size | 23.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e69859eeb1dc619f6c8c1941f04d855a7c9d51e0d27e1cefa7e2386fcc98b395
|
|
BLAKE2b-256 checksum How to use checksums |
8b5ea5bfbab49be4ad4925ac174ffd7d9b4335ea411cf20bc2fb7021268988cd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.31.0
|
Security for pytest-embedded-idf 2.10.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.