SPONSORS:






User Tag List

Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Nov 1999
    Location
    Chicago, IL USA
    Posts
    29
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Capturing Internet Explorer Script Error dialogs

    Javascript errors that cause the "Internet Explorer Script Error" dialog to appear immediately upon loading the page, are stopping my Silk scripts.

    I'd like to be able to handle and log these error messages when they occur, but I can't even get Record Identifiers or Record Window Declarations to run when they're on the screen....it's almost like they're killing the Agent.

    The other problem I've got is that even if I could get these windows declared, the error invariably occurs during a call to Browser.OnLoadPage. I'd prefer not to modify existing window methods in Segue supplied include files. Is there a way to "subclass" window methods? I've done a lot of work with derived methods on classes, but I don't know how to do this with the Browser declaration. Is it even possible?

  2. #2
    Junior Member
    Join Date
    Dec 1999
    Location
    San Mateo, CA, USA
    Posts
    17
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Capturing Internet Explorer Script Error dialogs

    Nancy,

    I am experiencing the same difficulty. I think that you're barking up the wrong tree with Browser.OnLoadPage(), however, because I only see this referenced within Browser.LoadPage, which is in turn referenced only within the DefaultBaseState() appstate within defaults.inc. Even if you were to place something in the OnLoadPage() method, it doesn't get called except when loading the main page from DefaultBaseState(), and I would suspect that you observe this error on other pages as well (I certainly have).

    A more direct approach is to override all of the events that can cause the pages to load. For instance the HtmlLink.Click() method could be extended to include a call to a function to look for error message boxes after the default event method is called, because that is when you will typically observe the error. With a previous project I was doing, I set up a message handler function to recognize, report and recover from common application run-time errors with C++ applications, then hooked a call to this function into every control event that was likely to trigger an error message (i.e. pushbutton clicks, menu picks, etc.)

    This was pretty darn effective for capturing these messages and reporting the problems succinctly, but in cases of GPF errors in Win95/98 and sometimes in WinNT, I still never could get the Agent to keep from locking up and stopping execution of the remaining intended testcases.

    This is a very real and basic hindrance to true recovery that Silktest regularly exhibits. If we have a body of tests, we obviously want as many of them to execute reliably in a given period of time as possible. If the application under-test and the agent lock up together in these cases, it can eat up a bunch of time while you modify scripts to avoid specific tests in order to make sure that the rest are executed.

    I am actually very surprised that Segue has not put more thought and effort into recovery from these kinds of situations, just like I am baffled as to how they can get away with such a weak set of tools for comparing and masking differences in text files used for comparison purposes.

    But I digress, if I come up with a way to insulate the agent from this kind of error and recover from it, I will definitely share, but I am not hopeful. I think this is simply a case of Segue needing to make the Agent processes more robust, and consider these abort and lock-up cases more carefully.

    ------------------
    Craig Koozer
    QA Engineer
    NetLedger, Inc.
    Craig Koozer
    Lead Test Automation Engineer
    www.oraclesmallbusiness.com

  3. #3
    Junior Member
    Join Date
    Dec 1999
    Location
    New York, New York, US
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Capturing Internet Explorer Script Error dialogs

    Thanks you, works like a charm.

  4. #4
    Junior Member
    Join Date
    Aug 1999
    Location
    Boston, MA
    Posts
    16
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Capturing Internet Explorer Script Error dialogs

    Won't SetTrap/ClearTrap work for this?

    ------------------
    John McGrail
    John McGrail

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin 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 07:38 AM.

Copyright BetaSoft Inc.