SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    May 2008
    Posts
    2
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    TP issues in layered windows

    Hello,

    I need help with the following issues I am currently facing with TestPartner.
    We have coded autoscripts for testing web application functionalities.However the framework of rendering dialogs/windows in the web application was changed to a one of layered window.This essentially is a Javascript technology used to render the dialogs with layers on top of the existing window.TestPartner has problems with the layered framework due to which all the existing scripts fail.

    Whenever an element on a layered dialog is attached by Testpartner (e.g. HTMLEditBox("<attach name>").Attach), it takes extremely long till this is done (approximately twice or triple of the performance for elements that are not located on a dialog). Of course all the other actions like Click etc. are not faster. Generic operations like e.g. Object("<attach name>").Attach (which usually work and still work for all other elements), now always fail (for elements on the dialogs).

    An issue exists if the Attach property tpAttachNoWait is used.
    For example if a test flow contains IF statements that perform actions depending on elements that exist, these IF checks might result in wrong conclusions.
    A test case might include a check whether a button is displayed or not. In the case that the button does not exist, that test should continue without getting red.
    Such a test is usually implemented by using the tpAttachNoWait property, which allows to test for the existence of an element without invoking a runtime error (without this option the test case gets red, when the button is not displayed).
    With the TP issue now, the check for existence with tpAttachNoWait always results in "false" for all elements placed on the new dialogs (even though they are clearly there).

    TestPartner version I am using currently 5.4.0 Build 180

    Any help to solve the issues is appreciated.

    Thanks in advance,

  2. #2
    Senior Member
    Join Date
    Apr 2003
    Location
    Wisconsin, USA
    Posts
    5,338
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: TP issues in layered windows

    First, an observation, then a question.

    Version 5.4.0 is getting quite dated. Why not update to the latest? There have been at least 3 updates since 5.4.0

    Question. Have you re-recorded your scripts since you went with the layered window approach? If not, that may well be the source of failure, since controls, windows, etc may have changed names, properties, or may even
    no longer exist.

    That may also be the cause of your attachnowait issue. If the control it is waiting on has changed properties and the control is in the object map, then the control you are waiting for indeed does not exist (with the properties that were originally recorded) even though you think they do exist, which will lead to the behavior you observe. Re-recording will also resolve this type of issue.

  3. #3
    Junior Member
    Join Date
    May 2008
    Posts
    2
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: TP issues in layered windows

    Hi DSquared,

    Thanks a lot for the timely suggestion and insight.
    On upgrading to TP 6.1 we find the core issues are solved and Layered windows are recognized.
    We are using coded scripts and not recorded ones.
    However for some basic Testpartner methods like setText and
    getText from an EditBox we face a strange situation:
    If the EditBox has a text by default the attachName of the EditBox also has the default value(text).
    The attachName had the following (tree)structure:
    =>Text value
    ==>Actual UI of the EditBox

    To analyze this we ran Step-by-Step and saw that
    the Function being called was attachedObject for attaching the editBox by passing the GUI information.The actual code used for this being:

    Dim attachedObject As TObject
    Set attachedObject = HTMLEditBox(attachName)

    ->Problem occurs at the above step because the default TestPartner method attachedObject seems to take the text value that was present in the EditBox instead of the "attachName" which has the UI information of the EditBox.

    Is there any TP setting that needs to be made so that the EditBox value is not taken here?
    Any help on this is appreciated.

    Thanks in advance.
    Roxy

  4. #4
    Senior Member
    Join Date
    Apr 2003
    Location
    Wisconsin, USA
    Posts
    5,338
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: TP issues in layered windows

    No settings that I know of.

    Instead of going through all the trouble of coding the attaches, why not take advantage of the power of TP?

    Get to the point in the code where you want to attach to the HTMLEditBox. Turn on record. Click on the box. Stop record.

    TP will then have generated the code required to attach to the edit box and you will see what is different between the generated code and the code that you wrote. First thing I think you will see is that there is no declaration of attachedObject as TObject. It is not needed.

    Try it and see. If the name of your HTMLEditBox caption is "My Edit Box", you will probably see something a single line that looks like this: HTMLEditBox("caption = 'My Edit Box'").Attach

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 11.11%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 01:47 AM.

Copyright BetaSoft Inc.