Product
Search Results

Can I run multiple startup scripts with the RestartDut testvar?

The RestartDut testvar supports execution of multiple startup scripts or commands. To utilize this functionality, each command must be separated with a semi-colon.

For example, assume two scripts have been written to control the device under test (DUT). One script reconfigures the DUT and is located in /usr/cdrouter-data/custom/scripts/reconfigure. The second script reboots the DUT and is located in /usr/cdrouter-data/custom/scripts/reboot. Both of these scripts can be called at the start of a test run using the RestartDut testvar:

testvar RestartDut "/usr/cdrouter-data/custom/scripts/reconfigure; sleep 30; /usr/cdrouter-data/custom/scripts/reboot"

Note that a delay of 30 seconds using the Linux sleep command was also inserted between the execution of each script in the above example.