Expanding the ZTEST shell to include a command that
accepts additional parameters, such as ztest run_testcase
<suite:test> -p any_value.
Adding the new ZTEST_P macro, to create the
parameterized test.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
A common question is how twister decides on which platform to run
a given test. Added section is meant to explain those rules.
Signed-off-by: Maciej Perkowski <Maciej.Perkowski@nordicsemi.no>
Extend pytest-args from configuration yaml file with args
from command line instead of overwriting.
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
Added python-tk to the brew install statement.
In order to use the zephyr gui tools python must also have the
"tkinter" (python tk interface) tools available.
tkinter is NOT part of 'python3' through homebrew on macOS.
fixes#76811
Signed-off-by: Eric Southam <eric.southam@lvt.com>
1.16 was not meant to be a release, and 1.14 was long ago.
Let's use as example something much more recent.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
When deprecating APIs,
let's tell users to add to one GitHub issue tracking all
deprecated APIs meant to be removed,
so the process is simpler and hopefully developers do it.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add a new fixture, `unlaunched_dut`, which is basically the `dut`
one, but without launching the device - thus also not building the
application. It is useful for tests who need a finer control of
the building of the application, before the dut can be launched
to run it.
It will be used on a future patch, which will use it to enable LLEXT EDK
tests.
Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
As it was already outlined, installing Python dependencies at a system
level or user level can be dangerous. For this reason, the default setup
instructions already pointed users to use Python virtual environments. On
newer Ubuntu installations (23.04 onwards) system-level pip installs are
not allowed. Let's make Zephyr _Python-safe_ as well by removing dangerous
instructions.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
probe-rs is a new programming and debugging tool written in Rust, supports
many probes and targets.
This commit introduces initial support for probe-rs to Zephyr.
Signed-off-by: Chen Xingyu <hi@xingrz.me>
Breathe is not very strict about the types used to reference C domain
objects (ex. referencing a struct using `:c:type:` would work, and vice
versa) but other tooling might be. This commit fixes some of such
incorrectly documented elements.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This reverts commit a156b619d4.
Now that Sphinx 7.4 is out, it is possible to use webp images
in the PDF documentation (they're converted to png).
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Apple has released other processors, e.g. M2 or M3, so Apple Silicon is no
longer a synonym of M1.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Add a diagram to illustrate a test application's project
components with relationships between Ztest and Twister
objects.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in various files within the `doc` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The current version of scipts do not consider OOT boards use cases and
the tests with robot now are strict to only one robot file, which is
not realistic for real environment. This address those issues and allow
multiple testsuits at command line and lists at tests entries. It add
another test parameter to allow configure robotframework options.
Fixes: #74563
Signed-off-by: Gerson Fernando Budke <gerson.budke@ossystems.com.br>
Terms like the west workspace or even west projects and modules were not
documented prominently enough, prompting users to ask for additional
clarification. This patch attempts to resolve this by adding terms and
explanation of concepts to the glossary and west doc pages.
Fixes#67376.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
This basic guide only covers linting so far. It could be expanded in the
future to be more accurate and detailed. The current configuration
allows to navigate the code but some symbols are not recognized by the
linter, and the native compiler is always used.
Co-authored-by: Enguerrand de Ribaucourt <enguerrand.de-ribaucourt@savoirfairelinux.com>
Co-authored-by: Luc BEAUFILS <luc.beaufils@savoirfairelinux.com>
Signed-off-by: Enguerrand de Ribaucourt <enguerrand.de-ribaucourt@savoirfairelinux.com>
Signed-off-by: Luc BEAUFILS <luc.beaufils@savoirfairelinux.com>
Remove legacy use of 'test case' and replace with `test scenario` where
applicable.
Update terminology and some other parts of twister docs.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
config file snippets should use "cfg" pygment to get proper highlighting
This commit updates all occurences where "kconfig" or other languages
were used.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fix a few issues with the probes documentation for NXP boards:
- fix references to debug probe type in probes page introduction
- add an explicit "Install the host tools" step for the LPC-Link and
MCU-Link based debug probe update steps.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Normally the return code of `CodeChecker analyze` and `CodeChecker parse`
is suppressed, so all the enabled commands can execute instead of
crashing the build.
Add a new option, `CODECHECKER_PARSE_EXIT_STATUS`, to permit failing the
build if `CodeChecker parse` returns non-zero.
Signed-off-by: Noah Pendleton <noah.pendleton@gmail.com>
Improve the SPDX with the current values:
- URL: extracted from `git remote`. If more than one remote, URL is not
set.
- Version: extracted from `git rev-parse` (commit id).
- PURL and CPE for Zephyr: generated from URL and version.
For zephyr, the tag is extracted, if present, and replace the commit id for
the version field.
Since official modules does not have tags, tags are not yet extracted for
modules.
To track vulnerabilities from modules dependencies, a new SBOM,
`modules-deps.spdx` was created. It contains the `external-references`
provided by the modules. It allows to easily track vulnerabilities from
these external dependencies.
Signed-off-by: Thomas Gagneret <thomas.gagneret@hexploy.com>
Extend Twister Harness recording feature to allow selected data fields,
extracted from the log by a regular expression, to be parsed into JSON
objects and eventually reported in `twister.json` as `recording` list
property of the test suite.
With this extension, log records can convey layered data structures
passed from a test image as summary results, traces, statistics, etc.
This extension also allows flexible recording structure: a test image
can output different types of data records incapsulated into a fixed
set of fields, so `recording.csv` file columns are respected, whereas
some of the columns keep strings with json-encoded semi-structured data.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Writing headers compatible with both C and C++ _and_ a range of
toolchains can be very challenging, see for instance long discussions in
commit c15f029a71 ("init.h: restore designated initializers in
SYS_INIT_NAMED()"), PR #69411 and a few others linked from there.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Update NXP flash debug probes section, to attempt to clarify the
differences between OpenSDA, LPC-Link2, and MCU-Link probes.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Allow twister fixtures to contain extra information, which can be used for
test suite configuration. The extra information can be appended to existing
fixtures separated by a colon (i.e. <fixture>:<configuration>).
This is especially useful for the pytest harness, where a fixture of a
given type may need to refer to an instance of a particular piece of host
hardware needed by the pytest suite (e.g. a network interface, a UART, or a
CAN interface connected to the device under test).
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Introduce `robot` command for running Robot Framework test suites.
Initial implementation consists of one runner dedicated for renode-test,
which is a Renode wrapper for running Robot tests.
Signed-off-by: Michał Szprejda <mszprejda@antmicro.com>
Introduce `simulate `command for running samples on a simulator of
choice. Initial implementation consists of one runner, dedicated for
Renode.
Signed-off-by: Michał Szprejda <mszprejda@antmicro.com>
Initial integration with renode-test was introduced in commit bdf02ff,
which added support for calling the `renode-test` command from both west
and twister.
This commit removes the custom run_renode_test target used for running
Robot tests with the `west build` command and makes twister call
`renode-test` directly instead.
Signed-off-by: Michał Szprejda <mszprejda@antmicro.com>
Installation of single toolchain causes problems for customers who
are not familiar with Zephyr infrastructure. This tip is supposed
to help them.
Signed-off-by: Nikolay Agishev <agishev@synopsys.com>
Update getting started guide, release notes, and CI actions to
use Python 3.10 as minimum supported version.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Removed Harness's repeat field.
Added to schemas in e722db14ad,
together with the rest of harness_config.
Added to Harness when it was created.
Now present only in one sample -
mec15xxevb_assy6853 power management sample.
Could not find definitive proof whether it has ever been used.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
LinkServer does not set a breakpoint at reset by default when debugging
platforms, so if the user single steps after loading an application they
will likely step through ROM code for the target. Add a note clarifying
that users need to set a breakpoint at the reset handler or "main" in
order to pause their application there.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Minor update to existing zspdx implementation to add support for
PrimaryPackagePurpose introduced in SPDX 2.3.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This test is intended to teach the conventions and best practices to a
potential contributor that wants to add a test, for say a new feature.
It is liberally commented on purpose, so new contributors don't have to
spend two weeks understanding the intricacies of the simulator, the bsim
test framework, the native builds, backchannels, etc..
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>