Problem: My automation script works fine when triggered from command line but fails when triggered by Test Collab.


Such errors can be annoying and end up taking a lot of your time. So if it has happened to you, we hope these steps can be of help:

Test Collab Remote Executor, the tool which triggers your automation script runs as a service in background. With Windows automation scripts/macros it is a common occurrence that services running in background usually cannot access objects/windows as we see on frontend. So make sure you verify that your scripts aren't failing because of this issue.

To do so, we'll simple first stop the Test Collab background service and then run the daemon manually. 

1. Stop Test Collab remote executor service:

Type services.msc in 'Run' > Find service named "Test Collab Remote Executor", right click and then Stop.

2. Now run the daemon in frontend manually:

Go to Run > Type 'cmd' and change current directory to path where you installed Test Collab Remote Executor

(Default path is: C:\Program Files\Test Collab\Remote Executor)

cd bin
node ..\src\index

This will show messages like:

checking for new execution to execute
Request info from http://localhost:8000/index.php/r...
Setting to check again in few minutes

3. Now trigger your automation script from Test Collab web panel or API once more and see how it goes.

If it succeeds, disable your service and create a simple batch file like below (just to give you an idea) in startup folder that runs Remote executor daemon in frontend.

cd C:\Program Files\Test Collab\Remote Executor\bin
node ..\src\index


Did this answer your question?