[qmtest] Synchronization between multiple instances of QMTest

Abhijeet Bisain abisain at qualcomm.com
Mon Sep 13 17:12:23 UTC 2004


So here's what I think might work, please let me know if I overlooked 
something.

I am thinking of adding a new outcome called BUSY, a new resource called 
ExclusiveAccessResource in a new file called exclusive.py. In the SetUp 
function, the resource will check for existence of a file 
"/tmp/qmtest_exclusive" or some file like that and if it exists, set the 
result outcome to BUSY, else it will create that file in Setup and then 
remove it in Cleanup.

I am planning on changing the CheckForResponse code in execution_engine.py 
to check for the result, and if the result said BUSY, then put the test 
back on the stack using the result id as the test id.

Thanks,
Abhijeet

At 10:35 PM 9/9/2004, Mark Mitchell wrote:
>Abhijeet Bisain wrote:
>
>>Hi,
>>
>>     Most of my test cases will be run on remote embedded targets and 
>> could be run from multiple hosts. What is the best way to prevent a 
>> target from running two tests from two different hosts that conflict 
>> with each other. For instance, the tests install a Linux kernel module 
>> and use it for something and they want exclusive access to it.
>>
>>     I was thinking of creating a new kind of resource which would create 
>> a file with a particular file name in the Setup and if the file exists, 
>> then return UNTESTED. Is there a better way?
>
>Are you talking about running multiple copies of QMTest simultaneously on 
>different hosts, but sharing the target boards between those copies?
>If you want to avoid conflicts in that setup, something like what you are 
>suggesting should work.
>
>--
>Mark Mitchell
>CodeSourcery, LLC
>(916) 791-8304
>mark at codesourcery.com




More information about the qmtest mailing list