How to keep local agent running 24x7?

So I just started using TestProject for automated web testing. due to the sensitivity of the data, I have to run them locally. However, when I scheduled my test suite for recurring test every 30 minutes overnight, I ended up getting error due to local agent not running:

TestProjectAPP 2:30 AM
Sanity run without login job has failed to start on Web Browser Agent @ 09:30
Agent [Web Browser Agent ($$$$$$$$$$$)] is not connected → aborting execution
Started By Scheduler
Agent Web Browser Agent
Platform Web
Targets Chrome

Is there a way to force my local agent to be up 24x7?


Hi @jcao,
Please make sure that your computer is turned on (not asleep) to ensure the agent doesn’t turn off.
If you still encounter the issue, you can create a system command to try and turn on the agent if it’s not already running:
Windows - use Schtasks
SCHTASKS /CREATE /RU YourUsername /RP YourPassword /SC DAILY /TN "TestProjectRun" /TR "C:\Program Files\TestProject Agent\start /min TestProjectAgent.exe" /ST 11:00

  • This command will try to run the agent daily at 11:00.

You can try the same for Linux and macOS.

You can also integrate to one of the supported cloud execution platforms to execute your test on the cloud:

Thank you Ran, really appreciate your quick answer above!

I am using MacOS and as I said before, I can’t run our tests in any cloud environment, it needs to stay local. What’s the default local agent runtime before it shuts down? Also, could you please provide the command for MacOS on how to invoke the agent every x minutes, please?

Thanks a lot!

Hi @jcao,
The agent is not set to shut down by itself unless there is an interference.
Regarding macOS - you can use your calendar to open the app:

1 - Open the calendar app and create a new event

2 - Set the event to repeat everyday at the same time

3 - In alert select custom > open file > > at time of event > ok:

4 - Select all:

Thank you Ran, this is very helpful. I have set it up following your steps, let’s see if this is enough to keep the agent live 24x7.

@jcao You are welcome :slightly_smiling_face: You can contact us any time for support.

This topic was automatically closed after 180 days. New replies are no longer allowed.