This example demonstrates how to log the results of a sequence call executed in a new thread using a wait step
When calling a subsequence from your TestStand sequence, you can optionally specify that the subsequence is run in a new thread, which allows the top level sequence to continue executing while the subsequence executes in parallel. However, this introduces an issue when collecting the results of the subsequence. For a traditional synchronous sequence call, the results for the sequence steps are propagated to the subsequence call step. With an asynchronous call, however, the subsequence call step has already finished executing when the subsequence completes. To address this, you can use a wait step in your calling sequence to wait for the subsequence to complete, and gather the results of the subsequence.
Follow these steps to configure a wait step to wait on a subsequence executed in a new thread:
Create a new wait step at the end of the top level sequence
In the wait settings for the step, select Thread.
Select Specify by Sequence Call, then select the subsequence call step from the drop-down, which is populated based on the steps in the current sequence
The wait step is now configured to wait for the new thread to complete, and will automatically gather the results of the thread.
The attached example demonstrates this concept with a simple subsequence.
Recording Results for a new Thread - TS2016
TestStand 2016 or compatible
Steps to Implement or Execute Code
Open the attached sequence file in TestStand.
Run the sequence using the Single Pass execution entry point.
Observe that the report shows the results of the new thread in the wait step results.