Test automation

Test automation
AUtomation

Friday, July 13, 2012

QTP - Terminal Emulator

Troubleshooting and Limitations - Terminal Emulator


This section contains general troubleshooting and limitation information about the Web add-in.

Installing and Loading the Terminal Emulator Add-in


When installing a Hummingbird HostExplorer terminal emulator or patches, make sure that QuickTest Professional is closed.
If the QuickTest Professional Terminal Emulator Add-in is installed and loaded, but there is no terminal emulator installed on your computer, the following error message is displayed: QuickTest Terminal Emulator support is not configured correctly. Either the terminal emulator is not installed on your computer or the HLLAPI DLL was not found.
Workaround: When you open QuickTest, clear the Terminal Emulators check box in the Add-in Manager.

Note: You can prevent this message from appearing by adjusting your emulator's configuration settings. For more information, see the HP QuickTest Professional Add-ins Guide.

You may experience unexpected behavior after you install an EXTRA! emulator. You may not be able to run QuickTest Professional or various features may stop working. This happens because the EXTRA! installation may have copied and registered an outdated version of the atl.dll file on your computer.
Workaround: Locate the atl.dll in your system folder (WINNT\system32). Its version should be 3.0 or higher. Register it with the regsvr32 utility.

Connecting and Disconnecting from the Terminal Emulator Add-in


If you have more than one terminal emulator session open, QuickTest does not recognize either session.
Workaround: While recording or running your test or component, make sure that only one terminal emulator session is connected at a time.

If your test or component contains steps that disconnect the current emulator session during the run session, followed immediately by a TeScreen.Sync command, the test or component run might stop responding or take a long time to respond.
Workaround: Remove the Sync command from the test or component, or replace it with a Wait statement. For more information, see the Utility Objects section of the HP QuickTest Professional Object Model Reference.

Inserting a checkpoint, creating a new test or component, or opening an existing test or component when the emulator session is busy may cause unexpected problems.
Workaround: Check the connection status of your emulator on the status line of the emulator screen before performing any of these operations.

Unexpected behavior may occur after disconnecting from a Host On-Demand session while recording.
Workaround: Stop recording before disconnecting from the session. Then, manually add a step that disconnects from the session.

You may experience unexpected behavior if the terminal emulator is closed while QuickTest is recording.

Configuration and Settings


When working with an emulator that does not support HLLAPI, or with an emulator that has been configured as supporting text-only HLLAPI operations, do not change the size of the terminal emulator window after configuring the emulator settings.
To enable support for a NetManage Web-To-Host Java Client session that is configured to open in a separate window, specify the title of your session window using the Tools > Options > Terminal Emulator > Adjust Configuration > Object identification settings > Identify emulator window based on title bar prefix option.
Tip: You may need to clear this value when switching to another configuration.

When using the Terminal Emulator Configuration Wizard to configure the screen sizes of NetManage RUMBA Web-to-Host, you cannot use the Mark Text Area option to draw on top of the emulator window.
Workaround: Configure the text area position of the screen manually.

Creating and Running Tests and Components


When using the OCR mechanism in order to perform steps requiring text recognition on non-HLLAPI emulators, the steps run slowly due to the required processing power of the OCR mechanism. Therefore, when testing non-HLLAPI emulators, it is recommended to select the default text recognition option: First Windows API then OCR in the Text Recognition pane of the Options dialog box.
The QuickTest Professional Terminal Emulator Add-in can identify emulator window objects only when the emulator is connected. For example, you cannot use the following statement to connect to an emulator session:
TeWindow("TeWindow").WinMenu("Menu").Select "Communication;Connect"

Workaround: You can record any steps that need to be performed prior to connection with the emulator. These steps are recorded as if the Terminal Emulator Add-in is not loaded. After the emulator is connected, stop the recording session and begin a new recording session to record terminal emulator objects.

When using an emulator that supports HLLAPI, if your emulator session disconnects from the host while recording, QuickTest no longer recognizes the emulator, even after reconnecting.
Workaround: Stop recording, reconnect the session, and continue recording.

When recording on a Hummingbird HostExplorer emulator, menu and toolbar operations in the emulator window are disabled.
Workaround: Stop recording, select the required menu item or click the required toolbar button, and continue recording.

When using an emulator that supports HLLAPI, closing the emulator window while recording may cause unexpected results.
Workaround: Stop recording before closing the emulator window.

The QuickTest Professional Terminal Emulator Add-in does not support recording operations on toolbar objects in terminal emulator applications.
Workaround: Record on the corresponding menu command for the toolbar button. Alternatively, you can use low-level recording to record operations on toolbars. For more information about low-level recording, see the HP QuickTest Professional User Guide.

If you record a test or component using one terminal emulator, it may not run correctly on another terminal emulator. For example, tests recorded on RUMBA may not run on IBM PCOM.
HostExplorer has a bug in the HLLAPI GetKey function. As a result, QuickTest will stop recording terminal emulator keyboard events after recording for a while, and the emulator might stop responding to keyboard events.
Workaround: Contact Hummingbird customer support to get the patch that fixes the problem with the HLLAPI GetKey function (where it stops responding after several calls).

Clicking, typing, or moving objects in the terminal emulator window while QuickTest is running a test or component may cause unexpected results.
Workaround: Wait until the end of the test or component, or pause the test or component execution before using the emulator.

To record and run tests or components on Hummingbird 9.0 5250 sessions, you need to install a patch for Hummingbird.
Workaround: Contact Hummingbird customer support to get the patch that fixes the problem with HLLAPI where all 5250 fields appear protected.

Working with Terminal Emulator Controls


When working with Attachmate Terminal Viewer 3.1 5250 session, all of the fields that appear on the screen before the first unprotected field are recognized as a single field.
QuickTest may not recognize a TeField object in a NetManage RUMBA session immediately after installing the emulator.
Workaround: Restart your computer after installing RUMBA, even if the installation does not request a restart.

Test Objects, Methods, and Properties


When using the SendKey method to unlock a terminal emulator, for example, TeWindow("TeWindow").TeScreen("screen5296").SendKey TE_RESET, some emulators (such as Host On-Demand) may not be unlocked.
Workaround: Specify the keyboard event to send for the RESET command, using the Tools > Options > Terminal Emulator > Adjust Configuration > Run Settings > Run steps containing special emulator keys using keyboard events > Keys for RESET function option.

By default, QuickTest uses the attached text and protected properties in TeField test object descriptions. If the attached text for a field changes from session to session, QuickTest cannot find the field during the run session.
Workaround: Open the Object Repository dialog box or the Object Properties dialog box for the object. Remove the attached text property from the field's description and add another property (or properties) such as start row, start column, or index to uniquely identify the object.

Tip: You can also create a smart identification definition for TeField objects so that your recorded test or component can run successfully even if the attached text property value for a particular TeField object changes. (Select Tools > Object Identification > Enable Smart Identification and click Configure.) For more information on Smart Identification, see the HP QuickTest Professional User Guide.

You cannot use the label property in a programmatic description of the TeScreen object. However, since only one screen can exist in the given TeWindow at any one time, you can use TeScreen("MicClass:=TeScreen").
For example:

TeWindow("short name:=A").TeScreen("MicClass:=TeScreen").TeField("attached text:=User", "Protected:=False").Set "33333"

The TeTextScreen properties current column and current row are available only for emulators that support HLLAPI.
The location property is not recorded for TeField objects.
Workaround: Use the index property instead.

Checkpoints and Output Values


In some cases, a bitmap checkpoint on a TeScreen may fail because the cursor shows in the expected bitmap, and not in the actual bitmap (or the other way around).

Workaround: Set the emulator cursor to a slow blink rate, or not to blink at all. This enhances the probability that the cursor is not captured in the bitmap.

Multilingual Support


When working with the IBM PCOM emulator, QuickTest may ignore special European language characters while recording or running a test or component.

Workaround: Set the code page for your IBM PCOM emulator in QuickTest, using the Tools > Options > Terminal Emulator > Adjust Configuration > Emulator settings > Code page number (IBM PCOM only) option.

10 comments:

balu.qtp.testing said...

Hi Rajshekar,
Thanks for info,

Could you please guide me the following as soon as possible

1. How to close TeWindow("TeWindow") ?

2. How to send "Esc" key on TESCREEN ?

Rajasekhar Matam said...

TeWindow("Window").TeTextScreen("Screen").Type micEsc

Thinakar said...

How to Sent Enter Key to TEScreen

Anonymous said...

TeWindow("Window").TeScreen("Screen").SendKey TE_ENTER

Unknown said...

QTP is identifying Terminal Emulator screen as WinObject.. can i know the problem.. i have installed TE addin also...

Sriram said...

Shyam J said.
QTP is identifying Terminal Emulator screen as WinObject.. can i know the problem.. i have installed TE addin also...

Hello Shyam, Open QTP with TE Addin alone , remove the rest of the Addins while opneing the QTP. This will to reslove your issue of QTP identifying Mainframes screen as Winobjects

Anonymous said...

Hi,

I've been using UFT with Attachmate and when my tests run the emulator takes a long time to complete tasks but when I do a manual run it runs smoothly and quickly. Is UFT affecting the performance of the emulator? Any way to fix this issue?

niveditha said...

How to get the cursor position on TE screen??

niveditha said...

How to get the cursor position on TE screen??

Anonymous said...

can anyone let me know to send combination keys like SHIFT+F3......