Ask a Question

Is it possible to check whether debug mode is enabled while running a test?

SOLVED
jr348
Contributor

Is it possible to check whether debug mode is enabled while running a test?

We're having problems with particular applications and would like to take additional desktop screenshots if debug mode is active.

 

Is it possible to find out the state of the debug button while running a test?

 

The Runner object seemed the obvious place but it does not have any properties related to this.

3 REPLIES 3
Marsha_R
Community Hero

Visualizer will do that for you.

https://support.smartbear.com/testcomplete/docs/testing-with/visualizer/about.html#images-captured-d...

 

Do you have it enabled?

https://support.smartbear.com/testcomplete/docs/working-with/managing-projects/properties/visualizer...


Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame

Thanks for the reply.  

 

The problematic keyword "test" is actually a support function is used at least twice in every test and so extends overall test run times, and massively increase log sizes if desktop screenshots are made.

 

We set the visualiser  "Capture Style" set to "top-level parent".  If we set it to "Desktop" it applies to every screenshot.  With a dual monitor system this has a significant storage and performance hit on a 5-6 hour test run.

 

We want to do a desktop screenshot in one particular test if it's in Debug mode.

 

It does not appear possible so we will work around it by adding a flag to our tests eg "Debug_Use_Desktop_Screenshots_In_XYZ" . This will cause a screenshot to be made of the Windows Explorer Desktop object.

Actually, you can access Debug status this way

https://support.smartbear.com/testcomplete/docs/reference/program-objects/dbgservices/options.html

 

You can also enable or disable Visualizer inside a test

https://support.smartbear.com/testcomplete/docs/testing-with/visualizer/enabling-and-disabling.html

 

 


Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
cancel
Showing results for 
Search instead for 
Did you mean: