问题
I am entering data from the DB to our application through protractor script.So now i am running the protractor script by the command 'protractor conf.js' from the command prompt.But i have to trigger the protractor script automatically instead of doing it manually from the command prompt.Do we have any methods or code for automatically trigger the protractor script in every specific time interval. Thanks in advance.
回答1:
Simplest way is to create a batch file with two commands and schedule a task with Operating systems Task scheduler.
- To cd to the project directory
- Trigger Protractor test
Example:
cd C:\Coding_Core\Protractor_tests
protractor conf.js
You should create a task with task scheduler and in trigger section specify the time and intervals
来源:https://stackoverflow.com/questions/52363750/how-can-we-automatically-trigger-the-protractor-script-at-specific-time-interval