On 28 January 2011 08:12, Paul Larson <paul.larson@linaro.org> wrote:
Other questions...


What does it do after running the test?  How, and where does it leave the results?  What get's added to the results (e.g. serial log) and how does that happen?  What is the mechanism for then taking that bundle and pushing to the server?  What happens if there were no results from the client, what do we capture in that case?
 
About the test result, I draft a test result bundle template, for a job test result bundle, it is stored in a text file.

Dispatcher server part will get the return value of the test case and the serial port log, then create test result together with some info from job message, client dispatcher test logs.

I think server dispatcher can fetch the client test logs initiatively after client dispatcher ends.

If there is no result from the client, after timeout,
1. server dispatcher send some "Ctrl+C" to client dispatcher to end it.
2. then restart the client dispatcher.
3. try to get the client dispatcher remained test logs.
4. mark the test case to TIMEOUT and create the test result.
PS. If step 1 can not end the client dispatcher, it may need a reboot for server dispatcher have lost the control of serial line.

Test result bundle composed of every test case result, for each test case result, it includes:

e.g.

And a test result bundle:


LOG
casename:PERF001
testsuite:abrek
testcmd:x11perf
timeout:60000
retvalue:0
version:2.6.35-xxxx
seriallog:
xxx
xxx
xxx
ENDLOG

LOG
casename:USB002
testsuite:abrek
testcmd:usb_app
timeout:60000
retvalue:0
version:2.6.35-xxxx
seriallog:
yyy
yyy
yyy
ENDLOG

What do you think?

The flow to get test result:
1. Server dispatcher sends commands to client dispatcher via serial line to invoke client dispatcher, capture all the serial log and wait for the client dispatcher ends.
2. Client dispatcher executes the command, save logs to some place on the board.
3. If client dispatcher ends normally(return to the "root@testimage:~$" string), server dispatcher uses "echo $?" to get the return value. Or terminate the client dispatcher after timeout.
4. Server dispatcher gets client dispatcher test logs.
5. Server dispatcher uses the collected information to create test result.


--
Best wishes,
Spring Zhang