Forum Discussion

jane_morris's avatar
jane_morris
Occasional Contributor
8 years ago

Is it possible to change an warning or error in the Test Log to a pass (green tick)?

Is it possible to change an warning or error in the Test Log to a pass (green tick)?  We have reoccurring warning which we would like to force the Test Log to change to show a green tick instead of the orange triangle.

 

Thanks

  • Manfred_F's avatar
    Manfred_F
    Regular Contributor

    Yes, can be done by Event handling.

    Catch warning Event, suppress and generate Checkpoint instead

    • tristaanogre's avatar
      tristaanogre
      Esteemed Contributor

      Manfred_F wrote:

      Yes, can be done by Event handling.

      Catch warning Event, suppress and generate Checkpoint instead


      AS Manfred_F, you can do it with event handling...

      ...but in my mind is the question: What is generating that warning message? Why is it happening? And what can I change in the test itself so I no longer get the warning?

      For example, there is, in an earlier version of TestComplete, a warning that comes up when you do a WaitProperty check on an object to see if it Exists and the object does not exist initially... that's KIND of a "duh" warning being logged that would be good to suppress.

      However, that warning can be mitigated by using a slightly different code logic to, instead of using WaitProperty, write a loop around WaitChild or WaitAliasChild until Exists is true... same overall result, but you no longer get the warnings.

      so... what warning are you getting, what is generating it, etc?  Because with that information, we might be able to give you a better solution than just changing the warning to a different log type or suppressing it all together.

  • jane_morris's avatar
    jane_morris
    Occasional Contributor

    Thanks for the responses.  As suggested we will try and investigate why the warnings are coming up to first.