Refactor PhabricatorListener
Summary:
This change moves the responsibility to perform the task
from the event listener to a dedicated job class.
The job class NotifyNewCommitsToDiffusion allows to call the
Phabricator API for any repository, not only for GitHub ones.
As a preparation for T851, we provide a getPhabricatorProject
method to allow to map source project and Phabricator project.
Ref. T851.
Test Plan:
- With artisan tinker, prepare a notification for rTOMMY
- Minimal test to check job wants a Phabricator API
Reviewers: dereckson
Maniphest Tasks: T851
Differential Revision: https://devcentral.nasqueron.org/D531