Forum Discussion

romanmfs's avatar
romanmfs
Frequent Contributor
7 years ago
Solved

Mobile screen stays ON when testing in Desktop

Hi!

 

I am new to Test Complete have very little experience. I am running keyword tests only. 

I recorded couple tests on our website and they run successfully. Then I recorded a mobile test which also runs perfect.

 

Issue: (when running a suite of 1 mobile and 1 desktop test right after). After completing mobile test, Test Complete starts testing Desktop test in Mobile view window. 

 

How do I fix this?

Thanks!

  • romanmfs's avatar
    romanmfs
    7 years ago

    Did not work, but! (it will maximize but the content will still be in that square)

    Hitting F12 twice did!

    THANKS!

9 Replies

    • romanmfs's avatar
      romanmfs
      Frequent Contributor

      Hi!

      Thanks for quick reply!

      I created a script as you suggested and it seems to work (it closes the process successfully).

       

      But after it closes and opens my next desktop test it is still in mobile view :(

       

      Here is the script I used to close Chrome:

       

       

       

      function CloseChrome()
      {
      // Obtains the notepad.exe process
      var p = Sys.Process("chrome");
      // Closes the process
      p.Close();
      // Checks whether the process is closed
      if (p.Exists)
      {
      Log.Warning(p.Chrome + " seems to hang, terminating.");
      p.SaveDumpToLog()
      // Terminates the process
      p.Terminate();
      }
      }

      • Marsha_R's avatar
        Marsha_R
        Champion Level 3

        And you're opening a brand new instance of Chrome afterwards?