InstructionsURL Property

Applies to TestComplete 14.10, last modified on June 5, 2019
The manual testing functionality is deprecated. Do not use it for creating new tests. It will be removed in a future TestComplete release.

Description

Use the InstructionsURL property to specify the name of the HTML file that holds instructions of the step that corresponds to ManualTestStep. If the step data is stored in the HTML format, then after you save the step to a file and create a project item from this file, the HTML file contents will be displayed in the Step instructions field of the Manual Test editor. To check the step text format, use the IsXMLContent method.

Declaration

ManualTestStepObj.InstructionsURL

Read-Write Property String
ManualTestStepObj An expression, variable or parameter that specifies a reference to a ManualTestStep object

Applies To

The property is applied to the following object:

Property Value

String specifying the name of the HTML file that holds the step instructions.

Remarks

Alternatively, you can specify the instruction's text directly. To do this use the InstructionsText property.

To define step instructions that are contained in an existing XML file, you should specify both the XMLFileName and XSLFileName properties.

Example

The following example demonstrates how to specify the test step instructions stored in an HTML file.

JavaScript, JScript

function ManualTest()
{
  ManualTestBuilder.Reset();
  ManualTestBuilder.Name = "NewManualTest";
  // Obtains the root step of the test and specifies its properties
  var RootStep = ManualTestBuilder.Root;
  RootStep.Caption = "Root step of my item";

  // Specifies the format of the file storing step instructions
  RootStep.IsXMLContent = false;
  // Specifies the HTML file that contains the step instructions
  RootStep.InstructionsURL = "C:\\Work Folder\\RootStep.htm";

  // Adds new substeps to the root step and specifies their properties
  ...

  // Saves the created test to a file
  ManualTestBuilder.Save("C:\\Work Folder\\ManualTest\\", true);

}

Python

def ManualTest():
  ManualTestBuilder.Reset()
  ManualTestBuilder.Name = "NewManualTest"
  # Obtains the root step of the test and specifies its properties
  RootStep = ManualTestBuilder.Root
  RootStep.Caption = "Root step of my item"
  # Specifies the format of the file storing step instructions
  RootStep.IsXMLContent = False
  # Specifies the HTML file that contains the step instructions
  RootStep.InstructionsURL = "C:\\Work Folder\\RootStep.htm"
  # Adds new substeps to the root step and specifies their properties
  # ...
  # Saves the created test to a file
  ManualTestBuilder.Save("C:\\Work Folder\\ManualTest\\", True)

VBScript

Sub ManualTest

  ManualTestBuilder.Reset
  ManualTestBuilder.Name = "NewManualTest"
  ' Obtains the root step of the test and specifies its properties
  Set RootStep = ManualTestBuilder.Root
  RootStep.Caption = "Root step of my item"

  ' Specifies the format of the file storing step instructions
  RootStep.IsXMLContent = False
  ' Specifies the HTML file that contains the step instructions
  RootStep.InstructionsURL = "C:\Work Folder\RootStep.htm"

  ' Adds new substeps to the root step and specifies their properties
  ...

  ' Saves the created test to a file
  Call ManualTestBuilder.Save("C:\Work Folder\ManualTest\", true)

End Sub

DelphiScript

procedure ManualTest();
var RootStep;
begin
  ManualTestBuilder.Reset;
  ManualTestBuilder.Name := 'NewManualTest';
  // Obtains the root step of the test and specifies its properties
  RootStep := ManualTestBuilder.Root;
  RootStep.Caption := 'Root step of my item';

  // Specifies the format of the file storing step instructions
  RootStep.IsXMLContent := false;
  // Specifies the HTML file that contains the step instructions
  RootStep.InstructionsURL := 'C:\Work Folder\RootStep.htm';

  // Adds new substeps to the root step and specifies their properties
  ...

  // Saves the created test to a file
  ManualTestBuilder.Save('C:\Work Folder\ManualTest\', true);

end;

C++Script, C#Script

function ManualTest()
{
  ManualTestBuilder["Reset"];
  ManualTestBuilder["Name"] = "NewManualTest";
  // Obtains the root step of the test and specifies its properties
  var RootStep = ManualTestBuilder["Root"];
  RootStep["Caption"] = "Root step of my item";

  // Specifies the format of the file storing step instructions
  RootStep["IsXMLContent"] = false;
  // Specifies the HTML file that contains the step instructions
  RootStep["InstructionsURL"] = "C:\\Work Folder\\RootStep.htm";

  // Adds new substeps to the root step and specifies their properties
  ...

  // Saves the created test to a file
  ManualTestBuilder["Save"]("C:\\Work Folder\\ManualTest\\", true);

}

See Also

Creating Manual Tests From Scripts
InstructionsText Property
XMLFileName Property
XSLFileName Property
IsXMLContent Property

Highlight search results