NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Parallel Test Sequences

Hello Community

I have some questions about testand parallel mode.
One is if I can run different sequences with different steps in parallel, this is because the sequences use different nests or sockets, one socket runs a sequence and another socket runs a completely different sequence.
Another question is how to share the resources since the nests will use the same hardware, I do not see very functional opening the communication in the preeuut of a socket,
blocking the instrument and making the second nest wait for the socket that took the instrument to finish the sequence and unlock the instrument,
I don't know if it is better to work it from the process model or some plugin or callback.
Consider that as I see it is to run the sequences as new threads, the problem here are the resources, if this is wrong, you can tell me everything, I take it into consideration.
If you know of any document or your answer, you can guide me

0 Kudos
Message 1 of 4
(240 Views)

From the TestStand Help, search for and read the article titled: "Parallel Test Strategies Demo"

 

Also see the demo:  

<TestStand Public>\Examples\Demos\Parallel Testing Strategies\Parallel Testing Strategies.seq

 

The demo will show strategies in managing shared resources using Lock or Auto Schedule

0 Kudos
Message 2 of 4
(223 Views)

"Lock" would be probably the simplest solution to secure parallel resources access.

Regarding different sequences: well, I don't think there is a ready-to-use template or pattern, you will need to modify the process model. The first solution that came into my mind is to create a "generic" client sequence file that would take a path to the actual sequence file as a parameter. This parameter value can differ between parallel executions. The "generic" sequence file would not execute real test steps, but would dynamically call the actual sequence inside.

0 Kudos
Message 3 of 4
(194 Views)

To build on that; remember that during execution you have access to the variable RunState.TestSockets.MyIndex.  This tells you the index of the parallel socket that is running. Use that variable in a Select..Case flow control; and when inside each case statement you can call into unique sequences that only that socket needs as suggested by @matowc.

0 Kudos
Message 4 of 4
(181 Views)