Teledyne LeCroy SAS_SATA Automation API manual User Manual

Page 125

Advertising
background image

 

Automation API for Teledyne LeCroy SAS/SATA Protocol Suite

119

SASVScriptEngine Object

Teledyne LeCroy

Example

C++:
// This example uses wrapper functions provided by the

#import directive.

ISASTrace* sas_trace;
. . .
ISASVerificationScript* sas_vscript = NULL;

sas_trace->QueryInterface(IID_ISASVerificationScript,
(void**)&sas_vscript ) )
assert( sas_vscript != NULL );

IVScriptEngine* sas_vsengine = NULL;
sas_vsengine = sas_vscript ->

GetVScriptEngine("Test_1");

assert( sas_vsengine != NULL );

VS_RESULT result = sas_vsengine ->RunVScript();
if( result == PASSED )
{
::MessageBox( NULL, "Test 1 passed !!!", "SASTracer

client", MB_OK );

}
result = sas_vsengine ->RunVScriptEx("Test_2");
if( result == PASSED )
{
::MessageBox( NULL, "Test 2 passed !!!", "SASTracer

client", MB_OK );

}
result = sas_vsengine -

>RunVScriptEx("C:\\MyTests\\Test_3.pevs");

if( result == PASSED )
{
::MessageBox( NULL, "Test 3 passed !!!", "SASTracer

client", MB_OK );

}
. . .

Advertising