@@ -113,7 +113,7 @@ report them as being skipped. Because the test inventory and
113113the list of tests is extracted from the code, adding
114114conditionals inside the test suite is sub-optimal. Tests that need
115115to be skipped for a certain platform or feature need to explicitly
116- report a skip using :c:func: `ztest_test_skip() `. If the test runs,
116+ report a skip using :c:func: `ztest_test_skip `. If the test runs,
117117it needs to report either a pass or fail. For example::
118118
119119 #ifdef CONFIG_TEST1
@@ -179,7 +179,7 @@ subcases that a Zephyr *ztest* test image will expose.
179179There exist two alternatives to writing tests. The first, and more verbose,
180180approach is to directly declare and run the test suites.
181181Here is a generic template for a test showing the expected use of
182- :func: `ztest_test_suite `:
182+ :c: func: `ztest_test_suite `:
183183
184184.. code-block :: C
185185
@@ -210,7 +210,7 @@ Here is a generic template for a test showing the expected use of
210210 }
211211
212212 Alternatively, it is possible to split tests across multiple files using
213- :func: `ztest_register_test_suite ` which bypasses the need for `extern `:
213+ :c: func: `ztest_register_test_suite ` which bypasses the need for `` extern ` `:
214214
215215.. code-block :: C
216216
@@ -224,16 +224,16 @@ Alternatively, it is possible to split tests across multiple files using
224224 ztest_unit_test(test_sometest1)
225225 );
226226
227- The above sample simple registers the test suite and uses a `NULL ` pragma
227+ The above sample simple registers the test suite and uses a `` NULL ` ` pragma
228228function (more on that later). It is important to note that the test suite isn't
229229directly run in this file. Instead two alternatives exist for running the suite.
230- First, if to do nothing. A default :func: ` test_main ` function is provided by
230+ First, if to do nothing. A default `` test_main ` ` function is provided by
231231ztest. This is the preferred approach if the test doesn't involve a state and
232232doesn't require use of the pragma.
233233
234234In cases of an integration test it is possible that some general state needs to
235235be set between test suites. This can be thought of as a state diagram in which
236- :func: ` test_main ` simply goes through various actions that modify the board's
236+ `` test_main ` ` simply goes through various actions that modify the board's
237237state and different test suites need to run. This is achieved in the following:
238238
239239.. code-block :: C
@@ -292,12 +292,12 @@ state and different test suites need to run. This is achieved in the following:
292292 }
293293
294294 For *twister * to parse source files and create a list of subcases,
295- the declarations of :func: `ztest_test_suite ` and
296- :func: `ztest_register_test_suite ` must follow a few rules:
295+ the declarations of :c: func: `ztest_test_suite ` and
296+ :c: func: `ztest_register_test_suite ` must follow a few rules:
297297
298298- one declaration per line
299299
300- - conditional execution by using :func: `ztest_test_skip `
300+ - conditional execution by using :c: func: `ztest_test_skip `
301301
302302What to avoid:
303303
@@ -339,7 +339,7 @@ What to avoid:
339339 ztest_unit_test(test_sometest4),
340340 ...
341341
342- - Do not add comments on lines with a call to :func: `ztest_unit_test `:
342+ - Do not add comments on lines with a call to :c: func: `ztest_unit_test `:
343343
344344 .. code-block :: C
345345
0 commit comments