AscentialTest Support Hub

Notifications

Clear all

Is it ok to use TaskKill to end a process during a test



1

Posts


1

Users


0

Reactions


22

Views

(@blesuer)
Member Admin

Joined: 4 months ago
Posts: 33

Topic starter
 

When you are using an automated testing tool like AscentialTest, the tool is hooked into the main process of the application that you are testing. When you kill that process using TaskKill, AscentialTest doesn’t have an opportunity to unhook. So it is not good practice to use TaskKill to close the application. Instead you should have a ‘recovery system’ built into your test class. OnStart and OnFinish are the virtual methods in the base class that you should be providing in your test class. If the application is to be closed after the conclusion of each test, then OnFinish should be responsible for making sure that it is closed gracefully, including looking for popups that might come up when you try to close the application and handling them from the GUI as the user would.



   

Quote

Share:

Can’t Find An Answer in the Forum?

Contact Our Team