Ask a Question

Has anyone had any joy creating and running tests on different size monitors

SOLVED
MegO
Contributor

Has anyone had any joy creating and running tests on different size monitors

Hi all,

 

My colleague and I are responsible for creating and running tests in TestComplete for our Desktop application.

 

The problem we face is that we both have different size monitors/Laptops with different resolution etc.

 

This means that tests created on one don't reliably work on the other.

 

Has anybody else faced this issue and how did they solve it?

 

Any ideas or suggestions would be greatly appreciated.

 

 

17 REPLIES 17

One thing i would check manually,  

 

  • Try to manually click the button where exactly TestComplete tried to click on the Big monitor, I have experienced a Object which will get work if i click on certain point at the Button.  
  • If you are able to click it manually, then just record that in TestComplete and try to see where it got clicked. You might get idea on this scenario.

 


Thanks
Shankar R

LinkedIn | CG-VAK Software | Bitbucket | shankarr.75@gmail.com

“You must expect great things from you, before you can do them”

Extension Available

tristaanogre
Esteemed Contributor

I'm not sure what OS version you're running, but there's an option in most versions of windows where you can "scale" the desktop.  Here's the screenshot from Windows 10 with the appropriate section highlighted.

2018-03-16 08_15_02-Settings.png

 

If scaling is set to something other than 100% (typically, set higher), then some of the ability to click on objects may be hampered.  All zoom and scaling settings should be set to 100% only...  Since the problem is happening on your "big" monitor, I'm guessing this zooming or scaling is increased beyond 100% and so TestComplete cannot accurately find the desired components.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

Hi tristaanogre,

 

We are both connecting to a W10 VM where we do not have options to change display settings.

 

My laptop (the smaller screen) has zoom set to 125% (Tests are working correctly) if I change this to 100% I can observe the tests fail on the remote session (This is the same setting the larger monitor has)

tristaanogre
Esteemed Contributor

There's your problem... if you created the tests with a zoom setting of 125% and are trying to run them at zoom of 100%, the scaling is off.  You need to have these things matching.  Correct this, then it doesn't matter what monitor you're on, it will work so long as the windows settings match.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

I know thats the problem, but I need a way to make them dynamic - Work in any environment.

 

Is there a way to do this apart from all the things I have attempted already?

 

Thank you 🙂

tristaanogre
Esteemed Contributor

I can't find the specific article at this moment... but I know that it's documented in the TestComplete documentation that, in order for tests to run consistently, the scaling needs to be the same on all environments.  So, you CAN run on different resolutions just fine... we do it all the time.  However, you need to make sure that the scaling is the same on all environments.  The resolution size (1024x768 versus whatever) is immaterial.... it's the scaling that is causing your issue.  Correct that, as documented, and you should be fine.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available

Thank you trsitanogre

Here's the article.

https://support.smartbear.com/testcomplete/docs/testing-with/specifics/testing-on-different-dpi-sett...

 

DOn't know the specifics of your application... but best bet (and best practice) is to keep your dpi settings/scaling consistent between your environments.  Sure, you can change them, but if you do so, you need to make sure that you create your tests appropriately... so, anything that is co-ordinate based, etc., will need to make sure it takes into account the different scaling... but the EASIEST way is to work with your administrators of your environments and tell them to set the scaling to 100%.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
cancel
Showing results for 
Search instead for 
Did you mean: