ZAPTEST finds object when it’s not on the screen

ZAPTEST finds object when it’s not on the screen

Home Forums Ask Expert ZAPTEST finds object when it’s not on the screen

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #32048
    Michał Szatkowski
    Participant

      Hi,

      When I’m running a test I want it to stop, when i.e. user provides wrong login. So after typing wrong login the screen stops, but the test goes on and is clicking on places where buttons were supposed to be, but are not, because I haven’t logged in. The test has a step, where it checks if an object exists and it is on a screen after logging in, so how is it possible that the test still finds it with 98% precision if it is not on the screen?

      It seems that zaptest is looking for objects on UI scans and not on the current screen during the test. Why is that happening or how can I solve this problem?

      Thanks,
      Michal

      #32050
      Kirill Bulatnikov
      Participant

        Hello Michal. Thanks for using ZAPTEST.
        It may be due some inappropriate objects or recognition type. In fact there are many reasons why this may happen.
        If you will upload your script we can take a look and check what may be wrong.

        Thanks.
        ZAPTEST Team

        #32059
        Michał Szatkowski
        Participant

          Thank you for responding.

          I’ve changed the script to look for text objects and it works better now, however during the test when it looks for an object and it doesn’t exist it takes about 20 (or more) seconds to go through the step and establish, that the object doesn’t exist (screenshot below). Is this normal? When the obcject exists Zaptest finds it preety fast. Can I somehow improve the timing?

          Thanks,
          Michael

          Attachments:
          #32060
          Kirill Bulatnikov
          Participant

            Hello Michael
            Yes, you are able to preset Exit method timeout.

            You can do it for entire ZAPTEST – go to Tools – Options – Runtime. And there you can find “Global Timeout” – the value in milliseconds, by default it is =45 seconds. You can set a value that is more acceptable to you.

            Another point is to set up Exist timeout for a specific step/code line. For example, in a step view, you can see parameter line below the Exist method – place cursor there and you will see the tooltip – it says that you can specify a timeout for Exist there. This way you can set it up specifically for the required object.

            Hope that helps.
            Thanks,
            ZAPTEST Team.

            #32061
            Michał Szatkowski
            Participant

              Problem solved. Thanks a lot!

            Viewing 5 posts - 1 through 5 (of 5 total)
            • You must be logged in to reply to this topic.

            Virtual Expert

            ZAPTEST

            ZAPTEST Logo