diff options
author | Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com> | 2016-04-21 12:43:51 -0700 |
---|---|---|
committer | Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com> | 2016-07-26 08:32:24 +0800 |
commit | eb2d8b418c8ca2f0e7031bed7db8440b65c15d2c (patch) | |
tree | 0b9ed273ac90ef5d7c7a7b168a338138f3e7417b /samples/ipm | |
parent | 11693c1bf9e32d21f230282d5b15e0a5e533a289 (diff) |
testcases: add automation markup to samples/
Code in samples does not follow an standarized format for reporting
success or operation failure -- thus we use markup (in file sample.tc)
to specify what shall be found in the console to consider execution a
success.
There is a few functional code modifications that add/extend console
messages so verification is possible or easier:
- hello_world, synchronization: extend the success message to also
print which core is running the testcase
- pci_enum: print message on success.
Change-Id: Idb6cea03adebe97d97854603f963f4e3d4cb856a
Signed-off-by: Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com>
Diffstat (limited to 'samples/ipm')
-rw-r--r-- | samples/ipm/sample.tc | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/samples/ipm/sample.tc b/samples/ipm/sample.tc new file mode 100644 index 000000000..5ebaadecc --- /dev/null +++ b/samples/ipm/sample.tc @@ -0,0 +1,35 @@ +# @testcase dynamic defaults=none +# @targets bsp_models:x86\+arc +# +# @build [ bsp == "x86" ] \ +# make -j -C %(srcdir)s/ipm_demo_lmt CONFIG_KERNEL_BIN_NAME=zephyr \ +# BOARD=%(board)s O=outdir-%(target)s-%(bsp_model)s-%(board)s +# @build [ bsp == "arc" ] \ +# make -j -C %(srcdir)s/ipm_demo_arc CONFIG_KERNEL_BIN_NAME=zephyr \ +# BOARD=%(board)s O=outdir-%(target)s-%(bsp_model)s-%(board)s +# +# @clean rm -rf %(srcdir)s/ipm_demo_*/outdir-%(target)s-%(bsp_model)s-* +# +# @images [ bsp == "x86" ] \ +# kernel-%(bsp)s:%(srcdir)s/ipm_demo_lmt/outdir-%(target)s-%(bsp_model)s-%(board)s/%(kernelname)s +# +# @images [ bsp == "arc" ] \ +# kernel-%(bsp)s:%(srcdir)s/ipm_demo_arc/outdir-%(target)s-%(bsp_model)s-%(board)s/%(kernelname)s +# +# +# Maybe we should switch to: Arduino has a hard time recovering some +# times, so we power cycle it instead of resetting +# @eval [ target == "arduino101" ] target-power-cycle one-shot wait=5 +# @eval [ target != "arduino101" ] target-reset one-shot +# +# ^eval [ bsp == 'arc' ] console-rx ::fail "unexpected data payload" +# ^eval [ bsp == 'arc' ] console-rx ::fail "expected [0-9]+ got [0-9]+" +# @eval [ bsp == 'arc' ] console-rx :15 counters: [0-9]+ [0-9]+ [0-9]+ +# @eval [ bsp == 'arc' ] console-rx :15 Hello from ARC + +# @eval [ bsp == 'x86' ] console-rx :15 Hello from lakemont! +# @eval [ bsp == 'x86' ] console-rx :15 === app started === +# @eval [ bsp == 'x86' ] console-rx :15 pinging arc for counter status +# @eval [ bsp == 'x86' ] console-rx :15 ARC (is (halted|sleeping|running)|status:) +# @eval [ bsp == 'x86' ] console-rx :15 mailbox status: [0-9a-f]+ mask [0-9a-f]+ +# @eval [ bsp == 'x86' ] console-rx :15 sending messages for IPM device |