What scenario I wanted to support? Please, let's consider that COMMAND_TEST is called so the following steps are correct:
user saves file A.php from project ProjectA
task is scheduled (to be run in 1 second)
user saves file AA.php from the same project ProjectA
the same task is scheduled again (to be run in 1 second); if the previously scheduled task did not run yet, it is cancelled and only the last scheduled task is run.
Having a task per project would be necessary to avoid cancelling task for running tests for ProjectA if any file from ProjectB is edited & saved in shorter interval than 1 second after a task for ProjectA was scheduled.
What scenario I wanted to support? Please, let's consider that COMMAND_TEST is called so the following steps are correct:
Having a task per project would be necessary to avoid cancelling task for running tests for ProjectA if any file from ProjectB is edited & saved in shorter interval than 1 second after a task for ProjectA was scheduled.