Bug 636 - no doc about sanity test process and case development
Summary: no doc about sanity test process and case development
Status: VERIFIED FIXED
Alias: None
Product: Reference
Classification: Documentation
Component: handbook (show other bugs)
Version: 1.0
Hardware: x86 Multiple
: Medium normal
Target Milestone: Future
Assignee: Scott Rifenbark
QA Contact:
URL:
Whiteboard: 16 June 2014: RESOLVED
: 3680 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-01-06 16:14 UTC by Kevin Tian
Modified: 2014-07-16 11:54 UTC (History)
10 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Done (doc changes complete)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Tian 2011-01-06 16:14:20 UTC
for this my memory may be vague. I recalled some place may contain this information, but didn't find it. Anyway, it may be worthy of a complete doc for how to run this automated test and also how to develop sanity test cases
Comment 1 Jiajun Xu 2011-01-06 16:32:34 UTC
(In reply to comment #0)
> for this my memory may be vague. I recalled some place may contain this
> information, but didn't find it. Anyway, it may be worthy of a complete doc for
> how to run this automated test and also how to develop sanity test cases

Yes. I used to write a wiki for sanity test how to, https://wiki.pokylinux.org/wiki/Enabling_Automation_Test_in_Poky. I can enhance the content in it since there are some changes these days. But I think for formal documentation, it's better to have ScottR write one.
Comment 2 Scott Rifenbark 2011-02-01 09:37:56 UTC
I need the raw information for this to assess how much of a doc this amounts to.
Comment 3 Alexandru Georgescu 2012-08-16 11:29:04 UTC
Kevin, Jiajun: Do you have the info Scott asked?

Thanks,
Alex.
Comment 4 Stoicescu Cornel 2013-02-13 16:24:52 UTC
This is an old one :)

Basically all the information that exists at the moment on automated sanity tests for qemu targets is contained in that wiki page. I believe Kevin was looking for that. 

More information I have on the subject:

-current setup works only for qemu image testing
-all tests are bash scripts
-all test scripts use functions defined in /scripts/qemuimage-testlib (these are handy)
-current tests are located in /scripts/qemuimage-tests/* excluding /scripts/qemuimage-tests/scenario
-scenarios are groups of tests categorized by architecture and target image type

How it works:

-after the qemu image is built, it is started using runqemu
-it uses a fixed wait timer to estime how long it takes the image to boot (I belive it's 60 seconds or so)
-after image is booted, a ssh connection is setup as root user
-the shell scripts are copied on the target machine and the output is captured
-using the output, a PASS or FAIL tag is added to that specific test
-the the tests are conducted and the complete result is stored in /opt/test/ on the target machine

Please note that we are planning to build on this. We would add more tests and ability to test BSP as well, though we don;t have a time frame at the moment.
Comment 5 Scott Rifenbark 2013-03-20 15:10:06 UTC
Here is how we will distribute the revised BB manual.  

* the "made" manuals will live alongside the current YP manuals on the yoctoproject.org server.  Before release time I will make a current version and an in progress version from the OE git repository.  I will publish these to the server, respectively.  Users will be able to access the manuals from the list of YP documentation.

* the repository for the BB manual will continue to live where it does with OE so that will not disrupt people that understand where it is.

* when Bill Traynor has Richard Purdie pull his area (wmat) into the OE repo, the result will be a yocto-ized structure that has multiple chapters, make file, etc.  this will be done before the 1.4 release at some point.  Bill is targeting end of March 2013 to lock it up.  At that point, he will tag the repo so we have a good 1.4 commit for the manual.  Work can continue on the tip where it can be incorporated into the "in progress" result just as we do with the YP manuals. 

Scott
Comment 6 Scott Rifenbark 2013-03-20 15:14:28 UTC
Ignore Comment 5.  was meant for a different bug... sorry.
Comment 7 Scott Rifenbark 2013-03-20 16:38:05 UTC
I seem to recall discussing this bug with Richard Purdie and it was decided to wait for full blown documentation until all tests were flushed out (see the last bit in comment 4 for how these are maybe not yet complete).  In the meantime, there are two classes in the YP Reference Manual that reference sanity testing in general:

* Host System Sanity Checks (http://www.yoctoproject.org/docs/1.4/ref-manual/ref-manual.html#ref-sanity-checks)

* Generated Output Quality Assurance Checks (http://www.yoctoproject.org/docs/1.4/ref-manual/ref-manual.html#ref-classes-insane)

What I was considering doing for now is to include two notes (one for each section) that point to the wiki page referenced in Comment 1 for for additional information on running sanity checks.  If a user is going to search for "sanity" in the mega-manual he will find this area and can learn more from the wiki at this point.

Let me know if this solution is good for 1.4.

Scott
Comment 8 Richard Purdie 2013-04-25 11:25:31 UTC
*** Bug 3680 has been marked as a duplicate of this bug. ***
Comment 9 Saul Wold 2013-04-29 23:14:32 UTC
Since we are working on more automation and possibly changing the test scripts, lets move this to 1.5
Comment 10 Scott Rifenbark 2013-09-19 00:49:09 UTC
Pushing out to post 1.5.
Comment 11 Scott Rifenbark 2014-03-11 20:48:19 UTC
Please look at my comment 7 and see if this is still a valid solution for this bug.

Scott
Comment 12 Scott Rifenbark 2014-06-16 12:17:09 UTC
Hi, 

I consulted Paul Eggleton and we have this issue documented now.  He has updated the wiki (https://wiki.yoctoproject.org/wiki/Enabling_Automation_Test_in_Poky) page such that it references back into our YP documentation.

I am marking the bug RESOLVED and updating the doc flag to "Done".

Scott
Comment 13 Stoicescu Cornel 2014-07-16 11:54:42 UTC
Documentation is in place. Setting to VERIFIED.