Share via


DTM Logger Example Using Tactics Scripting

The following code example shows the basics of using DTM Logger in Tactics scripting.

dim NameObj
dim Handle

Set NameObj = CreateObject("WTTLogger.Logger")

Handle = NameObj.CreateLogDevice("$LocalPub($LogFile:file=comtest;$Console;$Tactics)")

'  Test case ID
'  node path
'  Test case title -- set later
'  Hash key    
'  Created by
'  Modified by
'  Assigned to
'  Test type
'  Result type
'  Milestone
'  Priority
'  Test time
'  Comments
'  Method
'  Frequency
'  Description
'  Scripts
'  Log file path
'  Suite
'  Area
'  Component
'  Sub component
'  Dev
'  Test lead
'  Create only
'  Log only
'  Recursive

NameObj.Trace               _
    1024,                   _
    0,                      _
    -1,                     _
    "$\\DTM Logger\COM Test", _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    0,                      _
    1,                      _
    0                        

NameObj.Trace               _
    2048,                   _
    0,                      _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    NULL,                   _
    "3655.00",              _
    NULL,                   _
    NULL,                   _
    NULL                     

NameObj.StartTest "DTM Logger COM Test", 0

NameObj.Trace 33554432, 0, "test.vbs", 12, "This is an assert"

NameObj.EndTest "DTM Logger COM Test", 1, "This is the repro line", 0

NameObj.CloseLogDevice NULL, Handle

See Also

Code Samples for DTM Logger

Send feedback on this topic
Built on December 10, 2009