NameMapping.TimeOutWarning Property

Applies to TestComplete 15.69, last modified on November 13, 2024

Description

If you use Extended Find to search for tested objects and if your tested application contains a large number of objects, searching for a needed object may take much time. If the search takes more time than the Auto-wait timeout value, TestComplete will post the Search for a Mapped Object Took Too Much Time warning to the test log. To prevent TestComplete from posting the warning, you can either increase the Auto-wait timeout value (you can use the Options.Run.Timeout property to do it from tests), or use the NameMapping.TimeOutWarning property to suppress the warning.

Declaration

NameMapping.TimeOutWarning

Read-Write Property Boolean

Applies To

The property is applied to the following object:

Property Value

True if the message is posted, false otherwise.

Example

The following code snippet disables posting the message before the test, and enables it afterwards.

JavaScript, JScript

function NameMappingSample()
{
  // Disable the message
  NameMapping.TimeOutWarning = false;

  // Perform test actions that take long to find an object
  // …

  // Enable the message
  NameMapping.TimeOutWarning = true;

  // Continue the test run

}

Python

def NameMappingSample():
  # Disable the message 
  NameMapping.TimeOutWarning = False
  # Perform test actions that take long to find an object 
  # ...
  # Enable the message 
  NameMapping.TimeOutWarning = True
  # Continue the test run

VBScript

Sub NameMappingSample

  ' Disable the message
  NameMapping.TimeOutWarning = false

  ' Perform test actions that take long to find an object
  ' …

  ' Enable the message
  NameMapping.TimeOutWarning = true

  ' Continue the test run

End Sub

DelphiScript

procedure NameMappingSample();
begin
  // Disable the message
  NameMapping.TimeOutWarning := false;

  // Perform test actions that take long to find an object
  // …

  // Enable the message
  NameMapping.TimeOutWarning := true;

  // Continue the test run

end;

C++Script, C#Script

function NameMappingSample()
{
  // Disable the message
  NameMapping.TimeOutWarning = false;

  // Perform test actions that take long to find an object
  // …

  // Enable the message
  NameMapping.TimeOutWarning = true;

  // Continue the test run

}

See Also

NameMapping Object
Name Mapping - Extended Search
Project Properties - Playback Options
Options Object

Highlight search results