Test scripts can be executed via Windows tasks, but the following requirements must be met. How to set up a task in Windows is explained in many places on the internet, so this article does not cover that part. (A decent article explaining setting up tasks is How to Automatically Run Programs and Set Reminders With the Windows Task Scheduler , and here is Microsoft’s take on it: Using the Task Scheduler .)
A user must be logged on.
No screensaver must be running.
The console/screen must not be locked.
No RDP connection must have been made to the computer.
(Also see Automation on Windows for more details.)
Requirements for Windows 7 and 10¶
Run only if logged on¶
The task setting “Run only if user is logged on” must be enabled: