SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 3 of 3
  1. #1
    Junior Member
    Join Date
    Oct 2001
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Getting overall test status during run

    I would like to check the Test Result status (pass / fail) at run time. Scenario would be | reporter.ReportEvent micfail -- | and be able to check or evaluate that the test result is Failed.

    My goal is to have the test exit on failure rather than just error. Reason being client does not want to see failures unless the AUT is at fault so I am using warning where QTP may be causing the problem.

    Thanks
    Gary

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

    Re: Getting overall test status during run

    Not sure I understand the question. Are you bypassing checkpoints and coding your own logic to set a pass/fail status using the reporter.ReportEvent?

    If you want to stop execution prior to the end of the script, look into the ExitRun and/or ExitAction utility statements that you can code to stop the script execution.

    If the question is how to determine if a step has failed or not, a checkpoint actually returns a true/false value. Using the following you can set a variable to the boolean value and, with If Then Else logic, code up the behavior you desire, including whether or not to ExitRun
    Dim a
    a = browser("MyBrowser").page("MyPage").check (checkPoint("MyProperty"))

    Hope I'm not too far off from providing you the answer you needed.

  3. #3
    Senior Member
    Join Date
    Jan 2000
    Location
    USA, CA
    Posts
    1,998
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Getting overall test status during run

    Hi Gary
    You can control on appearance Pass\Fail indication in the Report by using Reporter Filter.
    From Help:
    Filter Property
    Retrieves or sets the current mode for displaying events in the Test Results. You can use this method to completely disable or enable reporting of steps following the statement, or you can indicate that you only want subsequent failed or failed and warning steps to be included in the report.
    ===============================================
    Activate the Filter right before the line you want to control. Like that:
    Reporter.Filter = rfDisableAll
    Then next line of your script, no matter what will be runTime Result, will be Reported as Done. Without indication Pass or Fail.
    Then you can restore ReporterFilter to show all results accordingly:
    Reporter.Filter = rfEnableAll
    Look for detail in the Help --> Reporter
    Regards
    Janna

 

 

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 10.71%
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 08:05 AM.

Copyright BetaSoft Inc.