From 00e5a4c5b40610ec849567d30f88e3ab8d0720fb Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Wed, 6 Jan 2016 21:46:31 -0500 Subject: Move Github Webhook to external plugin See: https://github.com/kanboard/plugin-github-webhook --- app/Controller/Webhook.php | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'app/Controller/Webhook.php') diff --git a/app/Controller/Webhook.php b/app/Controller/Webhook.php index a7e9bde4..82e9d635 100644 --- a/app/Controller/Webhook.php +++ b/app/Controller/Webhook.php @@ -40,25 +40,6 @@ class Webhook extends Base $this->response->text('FAILED'); } - /** - * Handle Github webhooks - * - * @access public - */ - public function github() - { - $this->checkWebhookToken(); - - $this->githubWebhook->setProjectId($this->request->getIntegerParam('project_id')); - - $result = $this->githubWebhook->parsePayload( - $this->request->getHeader('X-Github-Event'), - $this->request->getJson() - ); - - echo $result ? 'PARSED' : 'IGNORED'; - } - /** * Handle Gitlab webhooks * -- cgit v1.2.3 From 54b3cfe8a14e99ab2372fc5095facc3a2259f077 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Thu, 7 Jan 2016 20:16:05 -0500 Subject: Move bitbucket webhook to an external plugin --- ChangeLog | 1 + app/Action/CommentCreation.php | 3 - app/Action/TaskAssignUser.php | 6 +- app/Action/TaskClose.php | 3 - app/Action/TaskCreation.php | 2 - app/Action/TaskOpen.php | 2 - app/Controller/Webhook.php | 19 - app/Core/Base.php | 1 - app/Core/Event/EventManager.php | 7 - app/Integration/BitbucketWebhook.php | 312 ---------------- app/Locale/bs_BA/translations.php | 12 - app/Locale/cs_CZ/translations.php | 12 - app/Locale/da_DK/translations.php | 12 - app/Locale/de_DE/translations.php | 12 - app/Locale/es_ES/translations.php | 12 - app/Locale/fi_FI/translations.php | 12 - app/Locale/fr_FR/translations.php | 12 - app/Locale/hu_HU/translations.php | 12 - app/Locale/id_ID/translations.php | 12 - app/Locale/it_IT/translations.php | 12 - app/Locale/ja_JP/translations.php | 12 - app/Locale/nb_NO/translations.php | 12 - app/Locale/nl_NL/translations.php | 12 - app/Locale/pl_PL/translations.php | 12 - app/Locale/pt_BR/translations.php | 12 - app/Locale/pt_PT/translations.php | 12 - app/Locale/ru_RU/translations.php | 12 - app/Locale/sr_Latn_RS/translations.php | 12 - app/Locale/sv_SE/translations.php | 12 - app/Locale/th_TH/translations.php | 12 - app/Locale/tr_TR/translations.php | 12 - app/Locale/zh_CN/translations.php | 12 - app/ServiceProvider/ClassProvider.php | 1 - app/Template/project/integrations.php | 6 - doc/bitbucket-webhooks.markdown | 55 --- doc/github-webhooks.markdown | 99 ----- doc/index.markdown | 1 - tests/units/Integration/BitbucketWebhookTest.php | 399 --------------------- .../units/fixtures/bitbucket_comment_created.json | 147 -------- tests/units/fixtures/bitbucket_issue_assigned.json | 209 ----------- tests/units/fixtures/bitbucket_issue_closed.json | 183 ---------- tests/units/fixtures/bitbucket_issue_opened.json | 112 ------ tests/units/fixtures/bitbucket_issue_reopened.json | 183 ---------- .../units/fixtures/bitbucket_issue_unassigned.json | 193 ---------- tests/units/fixtures/bitbucket_push.json | 182 ---------- 45 files changed, 2 insertions(+), 2388 deletions(-) delete mode 100644 app/Integration/BitbucketWebhook.php delete mode 100644 doc/bitbucket-webhooks.markdown delete mode 100644 doc/github-webhooks.markdown delete mode 100644 tests/units/Integration/BitbucketWebhookTest.php delete mode 100644 tests/units/fixtures/bitbucket_comment_created.json delete mode 100644 tests/units/fixtures/bitbucket_issue_assigned.json delete mode 100644 tests/units/fixtures/bitbucket_issue_closed.json delete mode 100644 tests/units/fixtures/bitbucket_issue_opened.json delete mode 100644 tests/units/fixtures/bitbucket_issue_reopened.json delete mode 100644 tests/units/fixtures/bitbucket_issue_unassigned.json delete mode 100644 tests/units/fixtures/bitbucket_push.json (limited to 'app/Controller/Webhook.php') diff --git a/ChangeLog b/ChangeLog index 33539bb8..de916e7d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,7 @@ Breaking changes: * Action name stored in the database is now the absolute class name * Core functionalities moved to external plugins: - Github Webhook: https://github.com/kanboard/plugin-github-webhook + - Bitbucket Webhook: https://github.com/kanboard/plugin-bitbucket-webhook New features: diff --git a/app/Action/CommentCreation.php b/app/Action/CommentCreation.php index d7051d4d..e08ef47f 100644 --- a/app/Action/CommentCreation.php +++ b/app/Action/CommentCreation.php @@ -2,7 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\BitbucketWebhook; use Kanboard\Integration\GitlabWebhook; /** @@ -33,8 +32,6 @@ class CommentCreation extends Base public function getCompatibleEvents() { return array( - BitbucketWebhook::EVENT_ISSUE_COMMENT, - BitbucketWebhook::EVENT_COMMIT, GitlabWebhook::EVENT_COMMIT, GitlabWebhook::EVENT_ISSUE_COMMENT, ); diff --git a/app/Action/TaskAssignUser.php b/app/Action/TaskAssignUser.php index 0b4b55f5..da54d186 100644 --- a/app/Action/TaskAssignUser.php +++ b/app/Action/TaskAssignUser.php @@ -2,8 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\BitbucketWebhook; - /** * Assign a task to someone * @@ -31,9 +29,7 @@ class TaskAssignUser extends Base */ public function getCompatibleEvents() { - return array( - BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, - ); + return array(); } /** diff --git a/app/Action/TaskClose.php b/app/Action/TaskClose.php index 216d0f17..7f8af786 100644 --- a/app/Action/TaskClose.php +++ b/app/Action/TaskClose.php @@ -3,7 +3,6 @@ namespace Kanboard\Action; use Kanboard\Integration\GitlabWebhook; -use Kanboard\Integration\BitbucketWebhook; use Kanboard\Model\Task; /** @@ -36,8 +35,6 @@ class TaskClose extends Base return array( GitlabWebhook::EVENT_COMMIT, GitlabWebhook::EVENT_ISSUE_CLOSED, - BitbucketWebhook::EVENT_COMMIT, - BitbucketWebhook::EVENT_ISSUE_CLOSED, ); } diff --git a/app/Action/TaskCreation.php b/app/Action/TaskCreation.php index 909ee78c..8daa6726 100644 --- a/app/Action/TaskCreation.php +++ b/app/Action/TaskCreation.php @@ -3,7 +3,6 @@ namespace Kanboard\Action; use Kanboard\Integration\GitlabWebhook; -use Kanboard\Integration\BitbucketWebhook; /** * Create automatically a task from a webhook @@ -34,7 +33,6 @@ class TaskCreation extends Base { return array( GitlabWebhook::EVENT_ISSUE_OPENED, - BitbucketWebhook::EVENT_ISSUE_OPENED, ); } diff --git a/app/Action/TaskOpen.php b/app/Action/TaskOpen.php index 5cb626c3..efbcb874 100644 --- a/app/Action/TaskOpen.php +++ b/app/Action/TaskOpen.php @@ -3,7 +3,6 @@ namespace Kanboard\Action; use Kanboard\Integration\GitlabWebhook; -use Kanboard\Integration\BitbucketWebhook; /** * Open automatically a task @@ -34,7 +33,6 @@ class TaskOpen extends Base { return array( GitlabWebhook::EVENT_ISSUE_REOPENED, - BitbucketWebhook::EVENT_ISSUE_REOPENED, ); } diff --git a/app/Controller/Webhook.php b/app/Controller/Webhook.php index 82e9d635..be8bf030 100644 --- a/app/Controller/Webhook.php +++ b/app/Controller/Webhook.php @@ -54,23 +54,4 @@ class Webhook extends Base echo $result ? 'PARSED' : 'IGNORED'; } - - /** - * Handle Bitbucket webhooks - * - * @access public - */ - public function bitbucket() - { - $this->checkWebhookToken(); - - $this->bitbucketWebhook->setProjectId($this->request->getIntegerParam('project_id')); - - $result = $this->bitbucketWebhook->parsePayload( - $this->request->getHeader('X-Event-Key'), - $this->request->getJson() - ); - - echo $result ? 'PARSED' : 'IGNORED'; - } } diff --git a/app/Core/Base.php b/app/Core/Base.php index 88029f69..bbc51c50 100644 --- a/app/Core/Base.php +++ b/app/Core/Base.php @@ -45,7 +45,6 @@ use Pimple\Container; * @property \Kanboard\Core\Lexer $lexer * @property \Kanboard\Core\Paginator $paginator * @property \Kanboard\Core\Template $template - * @property \Kanboard\Integration\BitbucketWebhook $bitbucketWebhook * @property \Kanboard\Integration\GitlabWebhook $gitlabWebhook * @property \Kanboard\Formatter\ProjectGanttFormatter $projectGanttFormatter * @property \Kanboard\Formatter\TaskFilterGanttFormatter $taskFilterGanttFormatter diff --git a/app/Core/Event/EventManager.php b/app/Core/Event/EventManager.php index dd70f847..34a70900 100644 --- a/app/Core/Event/EventManager.php +++ b/app/Core/Event/EventManager.php @@ -3,7 +3,6 @@ namespace Kanboard\Core\Event; use Kanboard\Integration\GitlabWebhook; -use Kanboard\Integration\BitbucketWebhook; use Kanboard\Model\Task; use Kanboard\Model\TaskLink; @@ -59,12 +58,6 @@ class EventManager GitlabWebhook::EVENT_ISSUE_REOPENED => t('Gitlab issue reopened'), GitlabWebhook::EVENT_ISSUE_CLOSED => t('Gitlab issue closed'), GitlabWebhook::EVENT_ISSUE_COMMENT => t('Gitlab issue comment created'), - BitbucketWebhook::EVENT_COMMIT => t('Bitbucket commit received'), - BitbucketWebhook::EVENT_ISSUE_OPENED => t('Bitbucket issue opened'), - BitbucketWebhook::EVENT_ISSUE_CLOSED => t('Bitbucket issue closed'), - BitbucketWebhook::EVENT_ISSUE_REOPENED => t('Bitbucket issue reopened'), - BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE => t('Bitbucket issue assignee change'), - BitbucketWebhook::EVENT_ISSUE_COMMENT => t('Bitbucket issue comment created'), ); $events = array_merge($events, $this->events); diff --git a/app/Integration/BitbucketWebhook.php b/app/Integration/BitbucketWebhook.php deleted file mode 100644 index e6ba3f1a..00000000 --- a/app/Integration/BitbucketWebhook.php +++ /dev/null @@ -1,312 +0,0 @@ -project_id = $project_id; - } - - /** - * Parse incoming events - * - * @access public - * @param string $type Bitbucket event type - * @param array $payload Bitbucket event - * @return boolean - */ - public function parsePayload($type, array $payload) - { - switch ($type) { - case 'issue:comment_created': - return $this->handleCommentCreated($payload); - case 'issue:created': - return $this->handleIssueOpened($payload); - case 'issue:updated': - return $this->handleIssueUpdated($payload); - case 'repo:push': - return $this->handlePush($payload); - } - - return false; - } - - /** - * Parse comment issue events - * - * @access public - * @param array $payload - * @return boolean - */ - public function handleCommentCreated(array $payload) - { - $task = $this->taskFinder->getByReference($this->project_id, $payload['issue']['id']); - - if (! empty($task)) { - $user = $this->user->getByUsername($payload['actor']['username']); - - if (! empty($user) && ! $this->projectPermission->isAssignable($this->project_id, $user['id'])) { - $user = array(); - } - - $event = array( - 'project_id' => $this->project_id, - 'reference' => $payload['comment']['id'], - 'comment' => $payload['comment']['content']['raw']."\n\n[".t('By @%s on Bitbucket', $payload['actor']['display_name']).']('.$payload['comment']['links']['html']['href'].')', - 'user_id' => ! empty($user) ? $user['id'] : 0, - 'task_id' => $task['id'], - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_COMMENT, - new GenericEvent($event) - ); - - return true; - } - - return false; - } - - /** - * Handle new issues - * - * @access public - * @param array $payload - * @return boolean - */ - public function handleIssueOpened(array $payload) - { - $event = array( - 'project_id' => $this->project_id, - 'reference' => $payload['issue']['id'], - 'title' => $payload['issue']['title'], - 'description' => $payload['issue']['content']['raw']."\n\n[".t('Bitbucket Issue').']('.$payload['issue']['links']['html']['href'].')', - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_OPENED, - new GenericEvent($event) - ); - - return true; - } - - /** - * Handle issue updates - * - * @access public - * @param array $payload - * @return boolean - */ - public function handleIssueUpdated(array $payload) - { - $task = $this->taskFinder->getByReference($this->project_id, $payload['issue']['id']); - - if (empty($task)) { - return false; - } - - if (isset($payload['changes']['status'])) { - return $this->handleStatusChange($task, $payload); - } elseif (isset($payload['changes']['assignee'])) { - return $this->handleAssigneeChange($task, $payload); - } - - return false; - } - - /** - * Handle issue status change - * - * @access public - * @param array $task - * @param array $payload - * @return boolean - */ - public function handleStatusChange(array $task, array $payload) - { - $event = array( - 'project_id' => $this->project_id, - 'task_id' => $task['id'], - 'reference' => $payload['issue']['id'], - ); - - switch ($payload['issue']['state']) { - case 'closed': - $this->container['dispatcher']->dispatch(self::EVENT_ISSUE_CLOSED, new GenericEvent($event)); - return true; - case 'open': - $this->container['dispatcher']->dispatch(self::EVENT_ISSUE_REOPENED, new GenericEvent($event)); - return true; - } - - return false; - } - - /** - * Handle issue assignee change - * - * @access public - * @param array $task - * @param array $payload - * @return boolean - */ - public function handleAssigneeChange(array $task, array $payload) - { - if (empty($payload['issue']['assignee'])) { - return $this->handleIssueUnassigned($task, $payload); - } - - return $this->handleIssueAssigned($task, $payload); - } - - /** - * Handle issue assigned - * - * @access public - * @param array $task - * @param array $payload - * @return boolean - */ - public function handleIssueAssigned(array $task, array $payload) - { - $user = $this->user->getByUsername($payload['issue']['assignee']['username']); - - if (empty($user)) { - return false; - } - - if (! $this->projectPermission->isAssignable($this->project_id, $user['id'])) { - return false; - } - - $event = array( - 'project_id' => $this->project_id, - 'task_id' => $task['id'], - 'owner_id' => $user['id'], - 'reference' => $payload['issue']['id'], - ); - - $this->container['dispatcher']->dispatch(self::EVENT_ISSUE_ASSIGNEE_CHANGE, new GenericEvent($event)); - - return true; - } - - /** - * Handle issue unassigned - * - * @access public - * @param array $task - * @param array $payload - * @return boolean - */ - public function handleIssueUnassigned(array $task, array $payload) - { - $event = array( - 'project_id' => $this->project_id, - 'task_id' => $task['id'], - 'owner_id' => 0, - 'reference' => $payload['issue']['id'], - ); - - $this->container['dispatcher']->dispatch(self::EVENT_ISSUE_ASSIGNEE_CHANGE, new GenericEvent($event)); - - return true; - } - - /** - * Parse push events - * - * @access public - * @param array $payload - * @return boolean - */ - public function handlePush(array $payload) - { - if (isset($payload['push']['changes'])) { - foreach ($payload['push']['changes'] as $change) { - if (isset($change['new']['target']) && $this->handleCommit($change['new']['target'], $payload['actor'])) { - return true; - } - } - } - - return false; - } - - /** - * Parse commit - * - * @access public - * @param array $commit Bitbucket commit - * @param array $actor Bitbucket actor - * @return boolean - */ - public function handleCommit(array $commit, array $actor) - { - $task_id = $this->task->getTaskIdFromText($commit['message']); - - if (empty($task_id)) { - return false; - } - - $task = $this->taskFinder->getById($task_id); - - if (empty($task)) { - return false; - } - - if ($task['project_id'] != $this->project_id) { - return false; - } - - $this->container['dispatcher']->dispatch( - self::EVENT_COMMIT, - new GenericEvent(array( - 'task_id' => $task_id, - 'commit_message' => $commit['message'], - 'commit_url' => $commit['links']['html']['href'], - 'comment' => $commit['message']."\n\n[".t('Commit made by @%s on Bitbucket', $actor['display_name']).']('.$commit['links']['html']['href'].')', - ) + $task) - ); - - return true; - } -} diff --git a/app/Locale/bs_BA/translations.php b/app/Locale/bs_BA/translations.php index f58c3d6b..50b17c1b 100644 --- a/app/Locale/bs_BA/translations.php +++ b/app/Locale/bs_BA/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Već imaš jedan pod-zadatak "u radu"', 'Which parts of the project do you want to duplicate?' => 'Koje delove projekta želiš duplicirati?', 'Disallow login form' => 'Zabrani prijavnu formu', - 'Bitbucket commit received' => 'Bitbucket: commit dobijen', - 'Bitbucket webhooks' => 'Bitbucket: webhooks', - 'Help on Bitbucket webhooks' => 'Pomoć na Bitbucket webhooks', 'Start' => 'Početak', 'End' => 'Kraj', 'Task age in days' => 'Trajanje zadatka u danima', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Korisnik će dobiti email', 'Email subject' => 'Predmet email-a', 'Date' => 'Datum', - 'By @%s on Bitbucket' => 'Od @%s na Bitbucket', - 'Bitbucket Issue' => 'Bitbucket problem', - 'Commit made by @%s on Bitbucket' => 'Commit-ao @%s na Bitbucket', - 'Commit made by @%s on Gitlab' => 'Commit-ao @%s na Gitlab', 'Add a comment log when moving the task between columns' => 'Dodaj komentar u dnevnik kada se pomjeri zadatak između kolona', 'Move the task to another column when the category is changed' => 'Pomjeri zadatak u drugu kolonu kada je kategorija promijenjena', 'Send a task by email to someone' => 'Pošalji zadatak nekome emailom', 'Reopen a task' => 'Ponovo otvori zadatak', - 'Bitbucket issue opened' => 'Bitbucket: otvoren problem', - 'Bitbucket issue closed' => 'Bitbucket: zatvoren problem', - 'Bitbucket issue reopened' => 'Bitbucket: problem ponovo otvoren', - 'Bitbucket issue assignee change' => 'Bitbucket: promijenjen izvršilac problema', - 'Bitbucket issue comment created' => 'Bitbucket: dodan komentar na problemu', 'Column change' => 'Promijena kolone', 'Position change' => 'Promjena pozicije', 'Swimlane change' => 'Promjena swimline trake', diff --git a/app/Locale/cs_CZ/translations.php b/app/Locale/cs_CZ/translations.php index 9b65bd3b..8baba251 100644 --- a/app/Locale/cs_CZ/translations.php +++ b/app/Locale/cs_CZ/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Jeden dílčí úkol již aktuálně řešíte', 'Which parts of the project do you want to duplicate?' => 'Které části projektu chcete duplikovat?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket commit erhalten', - 'Bitbucket webhooks' => 'Bitbucket webhooks', - 'Help on Bitbucket webhooks' => 'Hilfe für Bitbucket webhooks', 'Start' => 'Začátek', 'End' => 'Konec', 'Task age in days' => 'Doba trvání úkolu ve dnech', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Uživatel, který dostane E-mail', 'Email subject' => 'E-mail Předmět', 'Date' => 'Datum', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', 'Add a comment log when moving the task between columns' => 'Přidat komentář když je úkol přesouván mezi sloupci', 'Move the task to another column when the category is changed' => 'Přesun úkolu do jiného sloupce když je změněna kategorie', 'Send a task by email to someone' => 'Poslat někomu úkol poštou', 'Reopen a task' => 'Znovu otevřít úkol', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', 'Column change' => 'Spalte geändert', 'Position change' => 'Position geändert', 'Swimlane change' => 'Swimlane geändert', diff --git a/app/Locale/da_DK/translations.php b/app/Locale/da_DK/translations.php index 99cf7ffb..dd531abb 100644 --- a/app/Locale/da_DK/translations.php +++ b/app/Locale/da_DK/translations.php @@ -578,9 +578,6 @@ return array( // 'You already have one subtask in progress' => '', // 'Which parts of the project do you want to duplicate?' => '', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', // 'Start' => '', // 'End' => '', // 'Task age in days' => '', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/de_DE/translations.php b/app/Locale/de_DE/translations.php index cbdc1fde..263e0421 100644 --- a/app/Locale/de_DE/translations.php +++ b/app/Locale/de_DE/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Bereits eine Teilaufgabe in Bearbeitung', 'Which parts of the project do you want to duplicate?' => 'Welcher Teil des Projekts soll kopiert werden?', 'Disallow login form' => 'Verbiete Login-Formular', - 'Bitbucket commit received' => 'Bitbucket-Commit erhalten', - 'Bitbucket webhooks' => 'Bitbucket-Webhooks', - 'Help on Bitbucket webhooks' => 'Hilfe für Bitbucket-Webhooks', 'Start' => 'Start', 'End' => 'Ende', 'Task age in days' => 'Aufgabenalter in Tagen', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Empfänger der E-Mail', 'Email subject' => 'E-Mail-Betreff', 'Date' => 'Datum', - 'By @%s on Bitbucket' => 'Durch @%s auf Bitbucket', - 'Bitbucket Issue' => 'Bitbucket-Issue', - 'Commit made by @%s on Bitbucket' => 'Commit von @%s auf Bitbucket', - 'Commit made by @%s on Gitlab' => 'Commit von @%s auf Gitlab', 'Add a comment log when moving the task between columns' => 'Kommentar hinzufügen, wenn Aufgabe in andere Spalte verschoben wird', 'Move the task to another column when the category is changed' => 'Aufgabe in andere Spalte verschieben, wenn Kategorie geändert wird', 'Send a task by email to someone' => 'Aufgabe per E-Mail versenden', 'Reopen a task' => 'Aufgabe wieder öffnen', - 'Bitbucket issue opened' => 'Bitbucket Ticket eröffnet', - 'Bitbucket issue closed' => 'Bitbucket Ticket geschlossen', - 'Bitbucket issue reopened' => 'Bitbucket Ticket wieder eröffnet', - 'Bitbucket issue assignee change' => 'Bitbucket Ticket Zuordnung geändert', - 'Bitbucket issue comment created' => 'Bitbucket Ticket Kommentar erstellt', 'Column change' => 'Spalte geändert', 'Position change' => 'Position geändert', 'Swimlane change' => 'Swimlane geändert', diff --git a/app/Locale/es_ES/translations.php b/app/Locale/es_ES/translations.php index 03a62976..aa08e35c 100644 --- a/app/Locale/es_ES/translations.php +++ b/app/Locale/es_ES/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Ya dispones de una subtarea en progreso', 'Which parts of the project do you want to duplicate?' => '¿Qué partes del proyecto desea duplicar?', 'Disallow login form' => 'Deshabilitar formulario de ingreso', - 'Bitbucket commit received' => 'Recibido envío desde Bitbucket', - 'Bitbucket webhooks' => 'Disparadores Web (webhooks) de Bitbucket', - 'Help on Bitbucket webhooks' => 'Ayuda sobre disparadores web (webhooks) de Bitbucket', 'Start' => 'Inicio', 'End' => 'Fin', 'Task age in days' => 'Edad de la tarea en días', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Usuario que recibirá el correo', 'Email subject' => 'Asunto del correo', 'Date' => 'Fecha', - 'By @%s on Bitbucket' => 'Mediante @%s en Bitbucket', - 'Bitbucket Issue' => 'Asunto de Bitbucket', - 'Commit made by @%s on Bitbucket' => 'Envío realizado por @%s en Bitbucket', - 'Commit made by @%s on Gitlab' => 'Envío realizado por @%s en Gitlab', 'Add a comment log when moving the task between columns' => 'Añadir un comentario al mover la tarea entre columnas', 'Move the task to another column when the category is changed' => 'Mover la tarea a otra columna cuando cambia la categoría', 'Send a task by email to someone' => 'Enviar una tarea a alguien por correo', 'Reopen a task' => 'Reabrir tarea', - 'Bitbucket issue opened' => 'Abierto asunto de Bitbucket', - 'Bitbucket issue closed' => 'Cerrado asunto de Bitbucket', - 'Bitbucket issue reopened' => 'Reabierto asunto de Bitbucket', - 'Bitbucket issue assignee change' => 'Cambiado concesionario de asunto de Bitbucket', - 'Bitbucket issue comment created' => 'Creado comentario de asunto de Bitbucket', 'Column change' => 'Cambio de columna', 'Position change' => 'Cambio de posición', 'Swimlane change' => 'Cambio de calle', diff --git a/app/Locale/fi_FI/translations.php b/app/Locale/fi_FI/translations.php index 1e72850d..e1a14749 100644 --- a/app/Locale/fi_FI/translations.php +++ b/app/Locale/fi_FI/translations.php @@ -578,9 +578,6 @@ return array( // 'You already have one subtask in progress' => '', // 'Which parts of the project do you want to duplicate?' => '', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', // 'Start' => '', // 'End' => '', // 'Task age in days' => '', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/fr_FR/translations.php b/app/Locale/fr_FR/translations.php index 1d85232b..f974584f 100644 --- a/app/Locale/fr_FR/translations.php +++ b/app/Locale/fr_FR/translations.php @@ -580,9 +580,6 @@ return array( 'You already have one subtask in progress' => 'Vous avez déjà une sous-tâche en progrès', 'Which parts of the project do you want to duplicate?' => 'Quelles parties du projet voulez-vous dupliquer ?', 'Disallow login form' => 'Interdire le formulaire d\'authentification', - 'Bitbucket commit received' => 'Commit reçu via Bitbucket', - 'Bitbucket webhooks' => 'Webhook Bitbucket', - 'Help on Bitbucket webhooks' => 'Aide sur les webhooks Bitbucket', 'Start' => 'Début', 'End' => 'Fin', 'Task age in days' => 'Âge de la tâche en jours', @@ -752,19 +749,10 @@ return array( 'User that will receive the email' => 'Utilisateur qui va reçevoir l\'email', 'Email subject' => 'Sujet de l\'email', 'Date' => 'Date', - 'By @%s on Bitbucket' => 'Par @%s sur Bitbucket', - 'Bitbucket Issue' => 'Ticket Bitbucket', - 'Commit made by @%s on Bitbucket' => 'Commit fait par @%s sur Bitbucket', - 'Commit made by @%s on Gitlab' => 'Commit fait par @%s sur Gitlab', 'Add a comment log when moving the task between columns' => 'Ajouter un commentaire d\'information lorsque une tâche est déplacée dans une autre colonne', 'Move the task to another column when the category is changed' => 'Déplacer une tâche vers une autre colonne lorsque la catégorie a changé', 'Send a task by email to someone' => 'Envoyer une tâche par email à quelqu\'un', 'Reopen a task' => 'Rouvrir une tâche', - 'Bitbucket issue opened' => 'Ticket Bitbucket ouvert', - 'Bitbucket issue closed' => 'Ticket Bitbucket fermé', - 'Bitbucket issue reopened' => 'Ticket Bitbucket rouvert', - 'Bitbucket issue assignee change' => 'Changement d\'assigné sur un ticket Bitbucket', - 'Bitbucket issue comment created' => 'Commentaire créé sur un ticket Bitbucket', 'Column change' => 'Changement de colonne', 'Position change' => 'Changement de position', 'Swimlane change' => 'Changement de swimlane', diff --git a/app/Locale/hu_HU/translations.php b/app/Locale/hu_HU/translations.php index 1c220016..392ead6c 100644 --- a/app/Locale/hu_HU/translations.php +++ b/app/Locale/hu_HU/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Már van egy folyamatban levő részfeladata', 'Which parts of the project do you want to duplicate?' => 'A projekt mely részeit szeretné másolni?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket commit érkezett', - 'Bitbucket webhooks' => 'Bitbucket webhooks', - 'Help on Bitbucket webhooks' => 'Bitbucket webhooks súgó', 'Start' => 'Kezdet', 'End' => 'Vég', 'Task age in days' => 'Feladat életkora napokban', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/id_ID/translations.php b/app/Locale/id_ID/translations.php index b9e8948d..9640abfb 100644 --- a/app/Locale/id_ID/translations.php +++ b/app/Locale/id_ID/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Anda sudah ada satu subtugas dalam proses', 'Which parts of the project do you want to duplicate?' => 'Bagian dalam proyek mana yang ingin anda duplikasi?', 'Disallow login form' => 'Larang formulir masuk', - 'Bitbucket commit received' => 'Menerima komit Bitbucket', - 'Bitbucket webhooks' => 'Webhook Bitbucket', - 'Help on Bitbucket webhooks' => 'Bantuan pada webhook Bitbucket', 'Start' => 'Mulai', 'End' => 'Selesai', 'Task age in days' => 'Usia tugas dalam hari', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Pengguna yang akan menerima email', 'Email subject' => 'Subjek Email', 'Date' => 'Tanggal', - 'By @%s on Bitbucket' => 'Oleh @%s pada Bitbucket', - 'Bitbucket Issue' => 'Tiket Bitbucket', - 'Commit made by @%s on Bitbucket' => 'Komit dibuat oleh @%s pada Bitbucket', - 'Commit made by @%s on Gitlab' => 'Komit dibuat oleh @%s pada Gitlab', 'Add a comment log when moving the task between columns' => 'Menambahkan log komentar ketika memindahkan tugas antara kolom', 'Move the task to another column when the category is changed' => 'Pindahkan tugas ke kolom lain ketika kategori berubah', 'Send a task by email to someone' => 'Kirim tugas melalui email ke seseorang', 'Reopen a task' => 'Membuka kembali tugas', - 'Bitbucket issue opened' => 'Tiket Bitbucket dibuka', - 'Bitbucket issue closed' => 'Tiket Bitbucket ditutup', - 'Bitbucket issue reopened' => 'Tiket Bitbucket dibuka kembali', - 'Bitbucket issue assignee change' => 'Perubahan penugasan tiket Bitbucket', - 'Bitbucket issue comment created' => 'Komentar dibuat tiket Bitbucket', 'Column change' => 'Kolom berubah', 'Position change' => 'Posisi berubah', 'Swimlane change' => 'Swimlane berubah', diff --git a/app/Locale/it_IT/translations.php b/app/Locale/it_IT/translations.php index 4d01d70c..81d1853f 100644 --- a/app/Locale/it_IT/translations.php +++ b/app/Locale/it_IT/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Hai già un sotto-compito in progresso', 'Which parts of the project do you want to duplicate?' => 'Quali parti del progetto vuoi duplicare?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Commit ricevuto da Bitbucket', - 'Bitbucket webhooks' => 'Webhooks di Bitbucket', - 'Help on Bitbucket webhooks' => 'Guida ai Webhooks di Bitbucket', 'Start' => 'Inizio', 'End' => 'Fine', 'Task age in days' => 'Anzianità del compito in giorni', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/ja_JP/translations.php b/app/Locale/ja_JP/translations.php index f98d96ee..3b24f224 100644 --- a/app/Locale/ja_JP/translations.php +++ b/app/Locale/ja_JP/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'すでに進行中のサブタスクがあります。', 'Which parts of the project do you want to duplicate?' => 'プロジェクトの何を複製しますか?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket コミットを受信しました', - 'Bitbucket webhooks' => 'Bitbucket Webhooks', - 'Help on Bitbucket webhooks' => 'Bitbucket Webhooks のヘルプ', 'Start' => '開始', 'End' => '終了', 'Task age in days' => 'タスクの経過日数', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/nb_NO/translations.php b/app/Locale/nb_NO/translations.php index 749630d9..75631126 100644 --- a/app/Locale/nb_NO/translations.php +++ b/app/Locale/nb_NO/translations.php @@ -578,9 +578,6 @@ return array( // 'You already have one subtask in progress' => '', 'Which parts of the project do you want to duplicate?' => 'Hvilke deler av dette prosjektet ønsker du å kopiere?', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', 'Start' => 'Start', 'End' => 'Slutt', 'Task age in days' => 'Dager siden oppgaven ble opprettet', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', 'Date' => 'Dato', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', 'Add a comment log when moving the task between columns' => 'Legg til en kommentar i loggen når en oppgave flyttes mellom kolonnene', 'Move the task to another column when the category is changed' => 'Flytt oppgaven til en annen kolonne når kategorien endres', 'Send a task by email to someone' => 'Send en oppgave på epost til noen', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', 'Column change' => 'Endret kolonne', 'Position change' => 'Posisjonsendring', 'Swimlane change' => 'Endret svømmebane', diff --git a/app/Locale/nl_NL/translations.php b/app/Locale/nl_NL/translations.php index 51148db5..5e1d2960 100644 --- a/app/Locale/nl_NL/translations.php +++ b/app/Locale/nl_NL/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'U heeft al een subtaak in behandeling', 'Which parts of the project do you want to duplicate?' => 'Welke onderdelen van het project wilt u dupliceren?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket commit ontvangen', - 'Bitbucket webhooks' => 'Bitbucket webhooks', - 'Help on Bitbucket webhooks' => 'Help bij Bitbucket webhooks', 'Start' => 'Start', 'End' => 'Eind', 'Task age in days' => 'Leeftijd taak in dagen', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/pl_PL/translations.php b/app/Locale/pl_PL/translations.php index 0356ab62..253e19f6 100644 --- a/app/Locale/pl_PL/translations.php +++ b/app/Locale/pl_PL/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Masz już zadanie o statusie "w trakcie"', 'Which parts of the project do you want to duplicate?' => 'Które elementy projektu chcesz zduplikować?', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', 'Start' => 'Początek', 'End' => 'Koniec', 'Task age in days' => 'Wiek zadania w dniach', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', 'Send a task by email to someone' => 'Wyślij zadanie mailem do kogokolwiek', 'Reopen a task' => 'Otwórz ponownie zadanie', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', 'Column change' => 'Zmiana kolumny', 'Position change' => 'Zmiana pozycji', 'Swimlane change' => 'Zmiana Swimlane', diff --git a/app/Locale/pt_BR/translations.php b/app/Locale/pt_BR/translations.php index 3873a4f9..ac063b16 100644 --- a/app/Locale/pt_BR/translations.php +++ b/app/Locale/pt_BR/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Você já tem um subtarefa em andamento', 'Which parts of the project do you want to duplicate?' => 'Quais partes do projeto você deseja duplicar?', 'Disallow login form' => 'Proibir o formulário de login', - 'Bitbucket commit received' => '"Commit" recebido via Bitbucket', - 'Bitbucket webhooks' => 'Webhook Bitbucket', - 'Help on Bitbucket webhooks' => 'Ajuda sobre os webhooks do Bitbucket', 'Start' => 'Início', 'End' => 'Fim', 'Task age in days' => 'Idade da tarefa em dias', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'O usuário que vai receber o e-mail', 'Email subject' => 'Assunto do e-mail', 'Date' => 'Data', - 'By @%s on Bitbucket' => 'Por @%s no Bitbucket', - 'Bitbucket Issue' => 'Bitbucket Issue', - 'Commit made by @%s on Bitbucket' => 'Commit feito por @%s no Bitbucket', - 'Commit made by @%s on Gitlab' => 'Commit feito por @%s no Gitlab', 'Add a comment log when moving the task between columns' => 'Adicionar um comentário de log quando uma tarefa é movida para uma outra coluna', 'Move the task to another column when the category is changed' => 'Mover uma tarefa para outra coluna quando a categoria mudou', 'Send a task by email to someone' => 'Enviar uma tarefa por e-mail a alguém', 'Reopen a task' => 'Reabrir uma tarefa', - 'Bitbucket issue opened' => 'Bitbucket issue opened', - 'Bitbucket issue closed' => 'Bitbucket issue closed', - 'Bitbucket issue reopened' => 'Bitbucket issue reopened', - 'Bitbucket issue assignee change' => 'Bitbucket issue assignee change', - 'Bitbucket issue comment created' => 'Bitbucket issue comment created', 'Column change' => 'Mudança de coluna', 'Position change' => 'Mudança de posição', 'Swimlane change' => 'Mudança de swimlane', diff --git a/app/Locale/pt_PT/translations.php b/app/Locale/pt_PT/translations.php index b7b154b8..fec3b724 100644 --- a/app/Locale/pt_PT/translations.php +++ b/app/Locale/pt_PT/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Já tem uma subtarefa em andamento', 'Which parts of the project do you want to duplicate?' => 'Quais as partes do projecto que deseja duplicar?', 'Disallow login form' => 'Desactivar login', - 'Bitbucket commit received' => '"Commit" recebido via Bitbucket', - 'Bitbucket webhooks' => 'Webhook Bitbucket', - 'Help on Bitbucket webhooks' => 'Ajuda sobre os webhooks Bitbucket', 'Start' => 'Inicio', 'End' => 'Fim', 'Task age in days' => 'Idade da tarefa em dias', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'O utilizador que vai receber o e-mail', 'Email subject' => 'Assunto do e-mail', 'Date' => 'Data', - 'By @%s on Bitbucket' => 'Por @%s no Bitbucket', - 'Bitbucket Issue' => 'Problema Bitbucket', - 'Commit made by @%s on Bitbucket' => 'Commit feito por @%s no Bitbucket', - 'Commit made by @%s on Gitlab' => 'Commit feito por @%s no Gitlab', 'Add a comment log when moving the task between columns' => 'Adicionar um comentário de log quando uma tarefa é movida para uma outra coluna', 'Move the task to another column when the category is changed' => 'Mover uma tarefa para outra coluna quando a categoria mudar', 'Send a task by email to someone' => 'Enviar uma tarefa por e-mail a alguém', 'Reopen a task' => 'Reabrir uma tarefa', - 'Bitbucket issue opened' => 'Problema aberto no Bitbucket', - 'Bitbucket issue closed' => 'Problema fechado no Bitbucket', - 'Bitbucket issue reopened' => 'Problema reaberto no Bitbucket', - 'Bitbucket issue assignee change' => 'Alterar assignação do problema no Bitbucket', - 'Bitbucket issue comment created' => 'Comentário ao problema adicionado ao Bitbucket', 'Column change' => 'Mudança de coluna', 'Position change' => 'Mudança de posição', 'Swimlane change' => 'Mudança de swimlane', diff --git a/app/Locale/ru_RU/translations.php b/app/Locale/ru_RU/translations.php index 0afd9b96..a8066115 100644 --- a/app/Locale/ru_RU/translations.php +++ b/app/Locale/ru_RU/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'У вас уже есть одна задача в разработке', 'Which parts of the project do you want to duplicate?' => 'Какие части проекта должны быть дублированы?', 'Disallow login form' => 'Запретить форму входа', - 'Bitbucket commit received' => 'Получен коммит с Bitbucket', - 'Bitbucket webhooks' => 'BitBucket webhooks', - 'Help on Bitbucket webhooks' => 'Помощь по BitBucket webhooks', 'Start' => 'Начало', 'End' => 'Конец', 'Task age in days' => 'Возраст задачи в днях', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Пользователь, который будет получать e-mail', 'Email subject' => 'Тема e-mail', 'Date' => 'Дата', - 'By @%s on Bitbucket' => 'Польз. @%s на Bitbucket', - 'Bitbucket Issue' => 'Задача Bitbucket', - 'Commit made by @%s on Bitbucket' => 'Коммит сделан польз. @%s на Bitbucket', - 'Commit made by @%s on Gitlab' => 'Коммит сделан польз. @%s в Gitlab', 'Add a comment log when moving the task between columns' => 'Добавлять запись при перемещении задачи между колонками', 'Move the task to another column when the category is changed' => 'Переносить задачи в другую колонку при изменении категории', 'Send a task by email to someone' => 'Отправить задачу по email', 'Reopen a task' => 'Переоткрыть задачу', - 'Bitbucket issue opened' => 'Открыта задача Bitbucket', - 'Bitbucket issue closed' => 'Закрыта задача Bitbucket', - 'Bitbucket issue reopened' => 'Переоткрыта задача Bitbucket', - 'Bitbucket issue assignee change' => 'Изменный назначенный для задачи на Bitbucket', - 'Bitbucket issue comment created' => 'Создан комментарий для задачи на Bitbucket', 'Column change' => 'Изменение колонки', 'Position change' => 'Позиция изменена', 'Swimlane change' => 'Дорожка изменена', diff --git a/app/Locale/sr_Latn_RS/translations.php b/app/Locale/sr_Latn_RS/translations.php index 5e56d805..b59e2e51 100644 --- a/app/Locale/sr_Latn_RS/translations.php +++ b/app/Locale/sr_Latn_RS/translations.php @@ -578,9 +578,6 @@ return array( // 'You already have one subtask in progress' => '', 'Which parts of the project do you want to duplicate?' => 'Koje delove projekta želite da kopirate', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', // 'Start' => '', // 'End' => '', // 'Task age in days' => '', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/sv_SE/translations.php b/app/Locale/sv_SE/translations.php index 67d0251f..bf6ee199 100644 --- a/app/Locale/sv_SE/translations.php +++ b/app/Locale/sv_SE/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Du har redan en deluppgift igång', 'Which parts of the project do you want to duplicate?' => 'Vilka delar av projektet vill du duplicera?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket bidrag mottaget', - 'Bitbucket webhooks' => 'Bitbucket webhooks', - 'Help on Bitbucket webhooks' => 'Hjälp för Bitbucket webhooks', 'Start' => 'Start', 'End' => 'Slut', 'Task age in days' => 'Uppgiftsålder i dagar', @@ -750,19 +747,10 @@ return array( 'User that will receive the email' => 'Användare som kommer att ta emot mailet', 'Email subject' => 'E-post ämne', 'Date' => 'Datum', - 'By @%s on Bitbucket' => 'Av @%s på Bitbucket', - 'Bitbucket Issue' => 'Bitbucket fråga', - 'Commit made by @%s on Bitbucket' => 'Bidrag gjort av @%s på Bitbucket', - 'Commit made by @%s on Gitlab' => 'Bidrag gjort av @%s på Gitlab', 'Add a comment log when moving the task between columns' => 'Lägg till en kommentarslogg när en uppgift flyttas mellan kolumner', 'Move the task to another column when the category is changed' => 'Flyttas uppgiften till en annan kolumn när kategorin ändras', 'Send a task by email to someone' => 'Skicka en uppgift med e-post till någon', 'Reopen a task' => 'Återöppna en uppgift', - 'Bitbucket issue opened' => 'Bitbucketfråga öppnad', - 'Bitbucket issue closed' => 'Bitbucketfråga stängd', - 'Bitbucket issue reopened' => 'Bitbucketfråga återöppnad', - 'Bitbucket issue assignee change' => 'Bitbucketfråga tilldelningsändring', - 'Bitbucket issue comment created' => 'Bitbucketfråga kommentar skapad', 'Column change' => 'Kolumnändring', 'Position change' => 'Positionsändring', 'Swimlane change' => 'Swimlaneändring', diff --git a/app/Locale/th_TH/translations.php b/app/Locale/th_TH/translations.php index 85197bc4..81946540 100644 --- a/app/Locale/th_TH/translations.php +++ b/app/Locale/th_TH/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'คุณมีหนึ่งงานย่อยที่กำลังทำงาน', // 'Which parts of the project do you want to duplicate?' => '', // 'Disallow login form' => '', - // 'Bitbucket commit received' => '', - // 'Bitbucket webhooks' => '', - // 'Help on Bitbucket webhooks' => '', 'Start' => 'เริ่ม', 'End' => 'จบ', 'Task age in days' => 'อายุงาน', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/tr_TR/translations.php b/app/Locale/tr_TR/translations.php index 25adf099..10472aad 100644 --- a/app/Locale/tr_TR/translations.php +++ b/app/Locale/tr_TR/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => 'Zaten işlemde olan bir alt görev var', 'Which parts of the project do you want to duplicate?' => 'Projenin hangi kısımlarının kopyasını oluşturmak istiyorsunuz?', // 'Disallow login form' => '', - 'Bitbucket commit received' => 'Bitbucket commit alındı', - 'Bitbucket webhooks' => 'Bitbucket webhooks', - 'Help on Bitbucket webhooks' => 'Bitbucket webhooks için yardım', 'Start' => 'Başlangıç', 'End' => 'Son', 'Task age in days' => 'Görev yaşı gün olarak', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', // 'Email subject' => '', // 'Date' => '', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', // 'Reopen a task' => '', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/Locale/zh_CN/translations.php b/app/Locale/zh_CN/translations.php index 53caba72..a152748f 100644 --- a/app/Locale/zh_CN/translations.php +++ b/app/Locale/zh_CN/translations.php @@ -578,9 +578,6 @@ return array( 'You already have one subtask in progress' => '你已经有了一个进行中的子任务', 'Which parts of the project do you want to duplicate?' => '要复制项目的哪些内容?', // 'Disallow login form' => '', - 'Bitbucket commit received' => '收到Bitbucket提交', - 'Bitbucket webhooks' => 'Bitbucket网络钩子', - 'Help on Bitbucket webhooks' => 'Bitbucket网络钩子帮助', 'Start' => '开始', 'End' => '结束', 'Task age in days' => '任务存在天数', @@ -750,19 +747,10 @@ return array( // 'User that will receive the email' => '', 'Email subject' => '邮件主题', 'Date' => '日期', - // 'By @%s on Bitbucket' => '', - // 'Bitbucket Issue' => '', - // 'Commit made by @%s on Bitbucket' => '', - // 'Commit made by @%s on Gitlab' => '', // 'Add a comment log when moving the task between columns' => '', // 'Move the task to another column when the category is changed' => '', // 'Send a task by email to someone' => '', 'Reopen a task' => '重新开始一个任务', - // 'Bitbucket issue opened' => '', - // 'Bitbucket issue closed' => '', - // 'Bitbucket issue reopened' => '', - // 'Bitbucket issue assignee change' => '', - // 'Bitbucket issue comment created' => '', // 'Column change' => '', // 'Position change' => '', // 'Swimlane change' => '', diff --git a/app/ServiceProvider/ClassProvider.php b/app/ServiceProvider/ClassProvider.php index 659d95b6..f7cd466c 100644 --- a/app/ServiceProvider/ClassProvider.php +++ b/app/ServiceProvider/ClassProvider.php @@ -116,7 +116,6 @@ class ClassProvider implements ServiceProviderInterface 'UserProfile', ), 'Integration' => array( - 'BitbucketWebhook', 'GitlabWebhook', ) ); diff --git a/app/Template/project/integrations.php b/app/Template/project/integrations.php index 6a149dbe..77b1b793 100644 --- a/app/Template/project/integrations.php +++ b/app/Template/project/integrations.php @@ -12,10 +12,4 @@

url->doc(t('Help on Gitlab webhooks'), 'gitlab-webhooks') ?>

- -

 

-
-
-

url->doc(t('Help on Bitbucket webhooks'), 'bitbucket-webhooks') ?>

-
\ No newline at end of file diff --git a/doc/bitbucket-webhooks.markdown b/doc/bitbucket-webhooks.markdown deleted file mode 100644 index 925615fa..00000000 --- a/doc/bitbucket-webhooks.markdown +++ /dev/null @@ -1,55 +0,0 @@ -Bitbucket webhooks -================== - -Bitbucket events can be connected to Kanboard automatic actions. - -List of supported events ------------------------- - -- Bitbucket commit received -- Bitbucket issue opened -- Bitbucket issue closed -- Bitbucket issue reopened -- Bitbucket issue assignee change -- Bitbucket issue comment created - -List of supported actions -------------------------- - -- Create a task from an external provider -- Change the assignee based on an external username -- Create a comment from an external provider -- Close a task -- Open a task - -Configuration -------------- - -![Bitbucket configuration](http://kanboard.net/screenshots/documentation/bitbucket-webhooks.png) - -1. On Kanboard, go to the project settings and choose the section **Integrations** -2. Copy the Bitbucket webhook URL -3. On Bitbucket, go to the project settings and go to the section **Webhooks** -4. Choose a title for your webhook and paste the Kanboard URL - -Examples --------- - -### Close a Kanboard task when a commit pushed to Bitbucket - -- Choose the event: **Bitbucket commit received** -- Choose action: **Close the task** - -When one or more commits are sent to Bitbucket, Kanboard will receive the information, each commit message with a task number included will be closed. - -Example: - -- Commit message: "Fix bug #1234" -- That will close the Kanboard task #1234 - -### Add comment when a commit received - -- Choose the event: **Bitbucket commit received** -- Choose action: **Create a comment from an external provider** - -The comment will contain the commit message and the URL to the commit. diff --git a/doc/github-webhooks.markdown b/doc/github-webhooks.markdown deleted file mode 100644 index a20b5a18..00000000 --- a/doc/github-webhooks.markdown +++ /dev/null @@ -1,99 +0,0 @@ -Github webhooks integration -=========================== - -Kanboard can be synchronized with Github. -Currently, it's only a one-way synchronization: Github to Kanboard. - -Github webhooks are plugged to Kanboard automatic actions. -When an event occurs on Github, an action can be performed on Kanboard. - -List of available events ------------------------- - -- Github commit received -- Github issue opened -- Github issue closed -- Github issue reopened -- Github issue assignee change -- Github issue label change -- Github issue comment created - -List of available actions -------------------------- - -- Create a task from an external provider -- Change the assignee based on an external username -- Change the category based on an external label -- Create a comment from an external provider -- Close a task -- Open a task - -Configuration on Github ------------------------ - -Go to your project settings page, on the left choose "Webhooks & Services", then click on the button "Add webhook". - -![Github configuration](http://kanboard.net/screenshots/documentation/github-webhooks.png) - -- **Payload url**: Copy and paste the link from the Kanboard project settings (section **Integrations > Github**). -- Select **"Send me everything"** - -![Github webhook](http://kanboard.net/screenshots/documentation/kanboard-github-webhooks.png) - -Each time an event happens, Github will send an event to Kanboard now. -The Kanboard webhook url is protected by a random token. - -Everything else is handled by automatic actions in your Kanboard project settings. - -Examples --------- - -### Close a Kanboard task when a commit pushed to Github - -- Choose the event: **Github commit received** -- Choose the action: **Close the task** - -When one or more commits are sent to Github, Kanboard will receive the information, each commit message with a task number included will be closed. - -Example: - -- Commit message: "Fix bug #1234" -- That will close the Kanboard task #1234 - -### Create a Kanboard task when a new issue is opened on Github - -- Choose the event: **Github issue opened** -- Choose the action: **Create a task from an external provider** - -When a task is created from a Github issue, the link to the issue is added to the description and the task have a new field named "Reference" (this is the Github ticket number). - -### Close a Kanboard task when an issue is closed on Github - -- Choose the event: **Github issue closed** -- Choose the action: **Close the task** - -### Reopen a Kanboard task when an issue is reopened on Github - -- Choose the event: **Github issue reopened** -- Choose the action: **Open the task** - -### Assign a task to a Kanboard user when an issue is assigned on Github - -- Choose the event: **Github issue assignee change** -- Choose the action: **Change the assignee based on an external username** - -Note: The username must be the same between Github and Kanboard and the user must be member of the project. - -### Assign a category when an issue is tagged on Github - -- Choose the event: **Github issue label change** -- Choose the action: **Change the category based on an external label** -- Define the label and the category - -### Create a comment on Kanboard when an issue is commented on Github - -- Choose the event: **Github issue comment created** -- Choose the action: **Create a comment from an external provider** - -If the username is the same between Github and Kanboard the comment author will be assigned, otherwise there is no author. -The user also have to be member of the project in Kanboard. diff --git a/doc/index.markdown b/doc/index.markdown index 0030e6d0..bc3a2fbf 100644 --- a/doc/index.markdown +++ b/doc/index.markdown @@ -68,7 +68,6 @@ Using Kanboard ### Integrations -- [Bitbucket webhooks](bitbucket-webhooks.markdown) - [Gitlab webhooks](gitlab-webhooks.markdown) - [iCalendar subscriptions](ical.markdown) - [RSS/Atom subscriptions](rss.markdown) diff --git a/tests/units/Integration/BitbucketWebhookTest.php b/tests/units/Integration/BitbucketWebhookTest.php deleted file mode 100644 index bb6755c2..00000000 --- a/tests/units/Integration/BitbucketWebhookTest.php +++ /dev/null @@ -1,399 +0,0 @@ -container['dispatcher']->addListener(BitbucketWebhook::EVENT_COMMIT, array($this, 'onCommit')); - - $tc = new TaskCreation($this->container); - $p = new Project($this->container); - $bw = new BitbucketWebhook($this->container); - $payload = json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_push.json'), true); - - $this->assertEquals(1, $p->create(array('name' => 'test'))); - $bw->setProjectId(1); - - // No task - $this->assertFalse($bw->handlePush($payload)); - - // Create task with the wrong id - $this->assertEquals(1, $tc->create(array('title' => 'test1', 'project_id' => 1))); - $this->assertFalse($bw->handlePush($payload)); - - // Create task with the right id - $this->assertEquals(2, $tc->create(array('title' => 'test2', 'project_id' => 1))); - $this->assertTrue($bw->handlePush($payload)); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertArrayHasKey(BitbucketWebhook::EVENT_COMMIT.'.BitbucketWebhookTest::onCommit', $called); - } - - public function testIssueOpened() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_OPENED, array($this, 'onIssueOpened')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $bw = new BitbucketWebhook($this->container); - $bw->setProjectId(1); - - $this->assertNotFalse($bw->parsePayload( - 'issue:created', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_opened.json'), true) - )); - } - - public function testCommentCreatedWithNoUser() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithNoUser')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:comment_created', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_comment_created.json'), true) - )); - } - - public function testCommentCreatedWithNotMember() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithNotMember')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'fguillot'))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:comment_created', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_comment_created.json'), true) - )); - } - - public function testCommentCreatedWithUser() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithUser')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'minicoders'))); - - $pp = new ProjectUserRole($this->container); - $this->assertTrue($pp->addUser(1, 2, Role::PROJECT_MEMBER)); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:comment_created', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_comment_created.json'), true) - )); - } - - public function testIssueClosed() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_CLOSED, array($this, 'onIssueClosed')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_closed.json'), true) - )); - } - - public function testIssueClosedWithNoTask() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_CLOSED, array($this, 'onIssueClosed')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 42, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_closed.json'), true) - )); - - $this->assertEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function testIssueReopened() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_REOPENED, array($this, 'onIssueReopened')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_reopened.json'), true) - )); - } - - public function testIssueReopenedWithNoTask() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_REOPENED, array($this, 'onIssueReopened')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 42, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_reopened.json'), true) - )); - - $this->assertEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function testIssueUnassigned() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, array($this, 'onIssueUnassigned')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_unassigned.json'), true) - )); - } - - public function testIssueAssigned() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, array($this, 'onIssueAssigned')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'minicoders'))); - - $pp = new ProjectUserRole($this->container); - $this->assertTrue($pp->addUser(1, 2, Role::PROJECT_MEMBER)); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_assigned.json'), true) - )); - - $this->assertNotEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function testIssueAssignedWithNoPermission() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, function () {}); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'minicoders'))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_assigned.json'), true) - )); - - $this->assertEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function testIssueAssignedWithNoUser() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, function () {}); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 1, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_assigned.json'), true) - )); - - $this->assertEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function testIssueAssignedWithNoTask() - { - $this->container['dispatcher']->addListener(BitbucketWebhook::EVENT_ISSUE_ASSIGNEE_CHANGE, function () {}); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 43, 'project_id' => 1))); - - $g = new BitbucketWebhook($this->container); - $g->setProjectId(1); - - $this->assertFalse($g->parsePayload( - 'issue:updated', - json_decode(file_get_contents(__DIR__.'/../fixtures/bitbucket_issue_assigned.json'), true) - )); - - $this->assertEmpty($this->container['dispatcher']->getCalledListeners()); - } - - public function onCommit($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(2, $data['task_id']); - $this->assertEquals('test2', $data['title']); - $this->assertEquals("Test another commit #2\n\n\n[Commit made by @Frederic Guillot on Bitbucket](https://bitbucket.org/minicoders/test-webhook/commits/824059cce7667d3f8d8780cc707391be821e0ea6)", $data['comment']); - $this->assertEquals("Test another commit #2\n", $data['commit_message']); - $this->assertEquals('https://bitbucket.org/minicoders/test-webhook/commits/824059cce7667d3f8d8780cc707391be821e0ea6', $data['commit_url']); - } - - public function onIssueOpened($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['reference']); - $this->assertEquals('My new issue', $data['title']); - $this->assertEquals("**test**\n\n[Bitbucket Issue](https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue)", $data['description']); - } - - public function onCommentCreatedWithNoUser($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(0, $data['user_id']); - $this->assertEquals(19176252, $data['reference']); - $this->assertEquals("1. step1\n2. step2\n\n[By @Frederic Guillot on Bitbucket](https://bitbucket.org/minicoders/test-webhook/issue/1#comment-19176252)", $data['comment']); - } - - public function onCommentCreatedWithNotMember($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(0, $data['user_id']); - $this->assertEquals(19176252, $data['reference']); - $this->assertEquals("1. step1\n2. step2\n\n[By @Frederic Guillot on Bitbucket](https://bitbucket.org/minicoders/test-webhook/issue/1#comment-19176252)", $data['comment']); - } - - public function onCommentCreatedWithUser($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(2, $data['user_id']); - $this->assertEquals(19176252, $data['reference']); - $this->assertEquals("1. step1\n2. step2\n\n[By @Frederic Guillot on Bitbucket](https://bitbucket.org/minicoders/test-webhook/issue/1#comment-19176252)", $data['comment']); - } - - public function onIssueClosed($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(1, $data['reference']); - } - - public function onIssueReopened($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(1, $data['reference']); - } - - public function onIssueAssigned($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(1, $data['reference']); - $this->assertEquals(2, $data['owner_id']); - } - - public function onIssueUnassigned($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(1, $data['reference']); - $this->assertEquals(0, $data['owner_id']); - } -} diff --git a/tests/units/fixtures/bitbucket_comment_created.json b/tests/units/fixtures/bitbucket_comment_created.json deleted file mode 100644 index 66a09bb8..00000000 --- a/tests/units/fixtures/bitbucket_comment_created.json +++ /dev/null @@ -1,147 +0,0 @@ -{ - "actor": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "repository": { - "full_name": "minicoders/test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "type": "repository", - "links": { - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - } - }, - "owner": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "name": "test-webhook" - }, - "comment": { - "content": { - "html": "
    \n
  1. step1
  2. \n
  3. step2
  4. \n
", - "raw": "1. step1\n2. step2", - "markup": "markdown" - }, - "created_on": "2015-06-21T02:51:40.532529+00:00", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1#comment-19176252" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments/19176252" - } - }, - "id": 19176252, - "user": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "updated_on": null - }, - "issue": { - "updated_on": "2015-06-21T02:51:40.536516+00:00", - "votes": 0, - "assignee": null, - "links": { - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - } - }, - "priority": "major", - "kind": "bug", - "watches": 1, - "edited_on": null, - "state": "new", - "content": { - "html": "

test

", - "raw": "**test**", - "markup": "markdown" - }, - "component": null, - "milestone": null, - "version": null, - "id": 1, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "type": "issue", - "reporter": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "title": "My new issue" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_issue_assigned.json b/tests/units/fixtures/bitbucket_issue_assigned.json deleted file mode 100644 index 0324afb2..00000000 --- a/tests/units/fixtures/bitbucket_issue_assigned.json +++ /dev/null @@ -1,209 +0,0 @@ -{ - "repository": { - "name": "test-webhook", - "type": "repository", - "full_name": "minicoders/test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - } - }, - "owner": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - } - }, - "changes": { - "responsible": { - "new": { - "is_system": false, - "name": "Frederic Guillot", - "username": "minicoders", - "id": 1290132, - "billing_external_uuid": null - }, - "old": null - }, - "assignee": { - "new": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "old": null - } - }, - "actor": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "issue": { - "repository": { - "links": { - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - } - }, - "type": "repository", - "full_name": "minicoders/test-webhook", - "name": "test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}" - }, - "edited_on": null, - "component": null, - "updated_on": "2015-06-21T15:21:28.023525+00:00", - "reporter": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "state": "open", - "content": { - "raw": "**test**", - "markup": "markdown", - "html": "

test

" - }, - "kind": "bug", - "links": { - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - } - }, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "watches": 1, - "milestone": null, - "version": null, - "assignee": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "title": "My new issue", - "priority": "major", - "id": 1, - "votes": 0, - "type": "issue" - }, - "comment": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments/19181255" - } - }, - "updated_on": null, - "content": { - "raw": null, - "markup": "markdown", - "html": "" - }, - "id": 19181255, - "created_on": "2015-06-21T15:21:28.043980+00:00", - "user": { - "display_name": "Frederic Guillot", - "type": "user", - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - } - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_issue_closed.json b/tests/units/fixtures/bitbucket_issue_closed.json deleted file mode 100644 index 473b5167..00000000 --- a/tests/units/fixtures/bitbucket_issue_closed.json +++ /dev/null @@ -1,183 +0,0 @@ -{ - "actor": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user", - "display_name": "Frederic Guillot", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "changes": { - "status": { - "old": "new", - "new": "closed" - } - }, - "repository": { - "full_name": "minicoders/test-webhook", - "type": "repository", - "links": { - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - } - }, - "owner": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user", - "display_name": "Frederic Guillot", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "name": "test-webhook" - }, - "comment": { - "content": { - "html": "", - "raw": null, - "markup": "markdown" - }, - "created_on": "2015-06-21T02:54:40.263014+00:00", - "updated_on": null, - "id": 19176265, - "user": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user", - "display_name": "Frederic Guillot", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments/19176265" - } - } - }, - "issue": { - "state": "closed", - "votes": 0, - "assignee": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user", - "display_name": "Frederic Guillot", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "links": { - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - } - }, - "priority": "major", - "version": null, - "watches": 1, - "edited_on": null, - "reporter": { - "username": "minicoders", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user", - "display_name": "Frederic Guillot", - "links": { - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - } - }, - "content": { - "html": "

test

", - "raw": "**test**", - "markup": "markdown" - }, - "component": null, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "updated_on": "2015-06-21T02:54:40.249466+00:00", - "kind": "bug", - "id": 1, - "milestone": null, - "type": "issue", - "repository": { - "full_name": "minicoders/test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "type": "repository", - "name": "test-webhook", - "links": { - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - } - } - }, - "title": "My new issue" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_issue_opened.json b/tests/units/fixtures/bitbucket_issue_opened.json deleted file mode 100644 index 7891c230..00000000 --- a/tests/units/fixtures/bitbucket_issue_opened.json +++ /dev/null @@ -1,112 +0,0 @@ -{ - "issue": { - "type": "issue", - "links": { - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - } - }, - "component": null, - "updated_on": "2015-06-21T02:17:40.990654+00:00", - "reporter": { - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "type": "user", - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "watches": 1, - "kind": "bug", - "edited_on": null, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "milestone": null, - "version": null, - "state": "new", - "assignee": null, - "content": { - "raw": "**test**", - "markup": "markdown", - "html": "

test

" - }, - "priority": "major", - "id": 1, - "votes": 0, - "title": "My new issue" - }, - "repository": { - "links": { - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - } - }, - "type": "repository", - "full_name": "minicoders/test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "name": "test-webhook", - "owner": { - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "type": "user", - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - } - }, - "actor": { - "links": { - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - } - }, - "username": "minicoders", - "type": "user", - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_issue_reopened.json b/tests/units/fixtures/bitbucket_issue_reopened.json deleted file mode 100644 index bb950916..00000000 --- a/tests/units/fixtures/bitbucket_issue_reopened.json +++ /dev/null @@ -1,183 +0,0 @@ -{ - "issue": { - "edited_on": null, - "watches": 1, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "reporter": { - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user" - }, - "content": { - "markup": "markdown", - "raw": "**test**", - "html": "

test

" - }, - "id": 1, - "milestone": null, - "repository": { - "full_name": "minicoders/test-webhook", - "type": "repository", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - } - }, - "name": "test-webhook" - }, - "component": null, - "version": null, - "votes": 0, - "priority": "major", - "type": "issue", - "state": "open", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - }, - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - } - }, - "kind": "bug", - "updated_on": "2015-06-21T14:56:49.739063+00:00", - "assignee": { - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user" - }, - "title": "My new issue" - }, - "comment": { - "id": 19181022, - "created_on": "2015-06-21T14:56:49.749362+00:00", - "content": { - "markup": "markdown", - "raw": null, - "html": "" - }, - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments/19181022" - } - }, - "user": { - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user" - }, - "updated_on": null - }, - "repository": { - "name": "test-webhook", - "owner": { - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user" - }, - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "type": "repository", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - } - }, - "full_name": "minicoders/test-webhook" - }, - "changes": { - "status": { - "new": "open", - "old": "closed" - } - }, - "actor": { - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "display_name": "Frederic Guillot", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "type": "user" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_issue_unassigned.json b/tests/units/fixtures/bitbucket_issue_unassigned.json deleted file mode 100644 index 3cbab2ea..00000000 --- a/tests/units/fixtures/bitbucket_issue_unassigned.json +++ /dev/null @@ -1,193 +0,0 @@ -{ - "comment": { - "updated_on": null, - "content": { - "html": "", - "markup": "markdown", - "raw": null - }, - "created_on": "2015-06-21T15:07:45.787623+00:00", - "user": { - "display_name": "Frederic Guillot", - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments/19181143" - } - }, - "id": 19181143 - }, - "issue": { - "state": "open", - "content": { - "html": "

test

", - "markup": "markdown", - "raw": "**test**" - }, - "milestone": null, - "type": "issue", - "version": null, - "title": "My new issue", - "assignee": null, - "kind": "bug", - "component": null, - "priority": "major", - "reporter": { - "display_name": "Frederic Guillot", - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "created_on": "2015-06-21T02:17:40.990654+00:00", - "edited_on": null, - "updated_on": "2015-06-21T15:07:45.775705+00:00", - "id": 1, - "votes": 0, - "repository": { - "full_name": "minicoders/test-webhook", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - } - }, - "type": "repository", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "name": "test-webhook" - }, - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1" - }, - "watch": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/watch" - }, - "vote": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/vote" - }, - "comments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/comments" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/issue/1/my-new-issue" - }, - "attachments": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/issues/1/attachments" - } - }, - "watches": 1 - }, - "actor": { - "display_name": "Frederic Guillot", - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "repository": { - "full_name": "minicoders/test-webhook", - "owner": { - "display_name": "Frederic Guillot", - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "type": "repository", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - } - }, - "name": "test-webhook", - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}" - }, - "changes": { - "responsible": { - "old": { - "is_system": false, - "username": "minicoders", - "name": "Frederic Guillot", - "billing_external_uuid": null, - "id": 1290132 - }, - "new": null - }, - "assignee": { - "old": { - "display_name": "Frederic Guillot", - "username": "minicoders", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}" - }, - "new": null - } - } -} \ No newline at end of file diff --git a/tests/units/fixtures/bitbucket_push.json b/tests/units/fixtures/bitbucket_push.json deleted file mode 100644 index f480b074..00000000 --- a/tests/units/fixtures/bitbucket_push.json +++ /dev/null @@ -1,182 +0,0 @@ -{ - "push": { - "changes": [ - { - "forced": false, - "old": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/refs/branches/master" - }, - "commits": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commits/master" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/branch/master" - } - }, - "name": "master", - "target": { - "date": "2015-06-21T00:50:37+00:00", - "hash": "b6b46580eb9b20a06396f5f697ea1a55cf170e69", - "message": "test edited online with Bitbucket for task #5", - "type": "commit", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commit/b6b46580eb9b20a06396f5f697ea1a55cf170e69" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/commits/b6b46580eb9b20a06396f5f697ea1a55cf170e69" - } - }, - "parents": [ - { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commit/7251db4b505cbfca3f845ebcff0ec0ddc4003ed8" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/commits/7251db4b505cbfca3f845ebcff0ec0ddc4003ed8" - } - }, - "type": "commit", - "hash": "7251db4b505cbfca3f845ebcff0ec0ddc4003ed8" - } - ], - "author": { - "raw": "Frederic Guillot ", - "user": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "username": "minicoders", - "display_name": "Frederic Guillot" - } - } - }, - "type": "branch" - }, - "created": false, - "links": { - "diff": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/diff/824059cce7667d3f8d8780cc707391be821e0ea6..b6b46580eb9b20a06396f5f697ea1a55cf170e69" - }, - "commits": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commits?include=824059cce7667d3f8d8780cc707391be821e0ea6exclude=b6b46580eb9b20a06396f5f697ea1a55cf170e69" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/branches/compare/824059cce7667d3f8d8780cc707391be821e0ea6..b6b46580eb9b20a06396f5f697ea1a55cf170e69" - } - }, - "new": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/refs/branches/master" - }, - "commits": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commits/master" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/branch/master" - } - }, - "name": "master", - "target": { - "date": "2015-06-21T03:15:08+00:00", - "hash": "824059cce7667d3f8d8780cc707391be821e0ea6", - "message": "Test another commit #2\n", - "type": "commit", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commit/824059cce7667d3f8d8780cc707391be821e0ea6" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/commits/824059cce7667d3f8d8780cc707391be821e0ea6" - } - }, - "parents": [ - { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook/commit/24aa9d82bbb6f9a60f743fe538deb0a44622fc98" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook/commits/24aa9d82bbb6f9a60f743fe538deb0a44622fc98" - } - }, - "type": "commit", - "hash": "24aa9d82bbb6f9a60f743fe538deb0a44622fc98" - } - ], - "author": { - "raw": "Frederic Guillot " - } - }, - "type": "branch" - }, - "closed": false - } - ] - }, - "repository": { - "name": "test-webhook", - "owner": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "username": "minicoders", - "display_name": "Frederic Guillot" - }, - "uuid": "{590fd9c4-0812-425e-8d72-ab08b4fd5735}", - "type": "repository", - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/repositories/minicoders/test-webhook" - }, - "html": { - "href": "https://bitbucket.org/minicoders/test-webhook" - }, - "avatar": { - "href": "https://bitbucket.org/minicoders/test-webhook/avatar/16/" - } - }, - "full_name": "minicoders/test-webhook" - }, - "actor": { - "links": { - "self": { - "href": "https://bitbucket.org/api/2.0/users/minicoders" - }, - "html": { - "href": "https://bitbucket.org/minicoders" - }, - "avatar": { - "href": "https://bitbucket.org/account/minicoders/avatar/32/" - } - }, - "type": "user", - "uuid": "{fc59b45a-f68b-4fc1-ad1f-a17d4f17cd2c}", - "username": "minicoders", - "display_name": "Frederic Guillot" - } -} \ No newline at end of file -- cgit v1.2.3 From 7864685cfdb64d2ef6497a445f0d8ed96762e4bf Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Thu, 7 Jan 2016 21:05:23 -0500 Subject: Move Gitlab webhook to an external plugin --- ChangeLog | 1 + app/Action/CommentCreation.php | 7 +- app/Action/TaskClose.php | 6 +- app/Action/TaskCreation.php | 6 +- app/Action/TaskOpen.php | 6 +- app/Controller/Webhook.php | 15 -- app/Core/Base.php | 1 - app/Core/Event/EventManager.php | 6 - app/Integration/GitlabWebhook.php | 298 ----------------------- app/Locale/bs_BA/translations.php | 10 +- app/Locale/cs_CZ/translations.php | 10 +- app/Locale/da_DK/translations.php | 10 +- app/Locale/de_DE/translations.php | 10 +- app/Locale/es_ES/translations.php | 10 +- app/Locale/fi_FI/translations.php | 10 +- app/Locale/fr_FR/translations.php | 10 +- app/Locale/hu_HU/translations.php | 10 +- app/Locale/id_ID/translations.php | 10 +- app/Locale/it_IT/translations.php | 10 +- app/Locale/ja_JP/translations.php | 10 +- app/Locale/nb_NO/translations.php | 10 +- app/Locale/nl_NL/translations.php | 10 +- app/Locale/pl_PL/translations.php | 10 +- app/Locale/pt_BR/translations.php | 10 +- app/Locale/pt_PT/translations.php | 10 +- app/Locale/ru_RU/translations.php | 10 +- app/Locale/sr_Latn_RS/translations.php | 10 +- app/Locale/sv_SE/translations.php | 10 +- app/Locale/th_TH/translations.php | 10 +- app/Locale/tr_TR/translations.php | 10 +- app/Locale/zh_CN/translations.php | 10 +- app/ServiceProvider/ClassProvider.php | 3 - app/Template/project/integrations.php | 12 +- doc/gitlab-webhooks.markdown | 70 ------ doc/index.markdown | 1 - tests/units/Integration/GitlabWebhookTest.php | 258 -------------------- tests/units/fixtures/gitlab_comment_created.json | 46 ---- tests/units/fixtures/gitlab_issue_closed.json | 25 -- tests/units/fixtures/gitlab_issue_opened.json | 25 -- tests/units/fixtures/gitlab_issue_reopened.json | 25 -- tests/units/fixtures/gitlab_push.json | 44 ---- 41 files changed, 33 insertions(+), 1042 deletions(-) delete mode 100644 app/Integration/GitlabWebhook.php delete mode 100644 doc/gitlab-webhooks.markdown delete mode 100644 tests/units/Integration/GitlabWebhookTest.php delete mode 100644 tests/units/fixtures/gitlab_comment_created.json delete mode 100644 tests/units/fixtures/gitlab_issue_closed.json delete mode 100644 tests/units/fixtures/gitlab_issue_opened.json delete mode 100644 tests/units/fixtures/gitlab_issue_reopened.json delete mode 100644 tests/units/fixtures/gitlab_push.json (limited to 'app/Controller/Webhook.php') diff --git a/ChangeLog b/ChangeLog index de916e7d..887172ce 100644 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,7 @@ Breaking changes: * Action name stored in the database is now the absolute class name * Core functionalities moved to external plugins: - Github Webhook: https://github.com/kanboard/plugin-github-webhook + - Gitlab Webhook: https://github.com/kanboard/plugin-gitlab-webhook - Bitbucket Webhook: https://github.com/kanboard/plugin-bitbucket-webhook New features: diff --git a/app/Action/CommentCreation.php b/app/Action/CommentCreation.php index e08ef47f..b91e39e2 100644 --- a/app/Action/CommentCreation.php +++ b/app/Action/CommentCreation.php @@ -2,8 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\GitlabWebhook; - /** * Create automatically a comment from a webhook * @@ -31,10 +29,7 @@ class CommentCreation extends Base */ public function getCompatibleEvents() { - return array( - GitlabWebhook::EVENT_COMMIT, - GitlabWebhook::EVENT_ISSUE_COMMENT, - ); + return array(); } /** diff --git a/app/Action/TaskClose.php b/app/Action/TaskClose.php index 7f8af786..b8c5e175 100644 --- a/app/Action/TaskClose.php +++ b/app/Action/TaskClose.php @@ -2,7 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\GitlabWebhook; use Kanboard\Model\Task; /** @@ -32,10 +31,7 @@ class TaskClose extends Base */ public function getCompatibleEvents() { - return array( - GitlabWebhook::EVENT_COMMIT, - GitlabWebhook::EVENT_ISSUE_CLOSED, - ); + return array(); } /** diff --git a/app/Action/TaskCreation.php b/app/Action/TaskCreation.php index 8daa6726..290c31e1 100644 --- a/app/Action/TaskCreation.php +++ b/app/Action/TaskCreation.php @@ -2,8 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\GitlabWebhook; - /** * Create automatically a task from a webhook * @@ -31,9 +29,7 @@ class TaskCreation extends Base */ public function getCompatibleEvents() { - return array( - GitlabWebhook::EVENT_ISSUE_OPENED, - ); + return array(); } /** diff --git a/app/Action/TaskOpen.php b/app/Action/TaskOpen.php index efbcb874..ec0f96f7 100644 --- a/app/Action/TaskOpen.php +++ b/app/Action/TaskOpen.php @@ -2,8 +2,6 @@ namespace Kanboard\Action; -use Kanboard\Integration\GitlabWebhook; - /** * Open automatically a task * @@ -31,9 +29,7 @@ class TaskOpen extends Base */ public function getCompatibleEvents() { - return array( - GitlabWebhook::EVENT_ISSUE_REOPENED, - ); + return array(); } /** diff --git a/app/Controller/Webhook.php b/app/Controller/Webhook.php index be8bf030..0eafe3e5 100644 --- a/app/Controller/Webhook.php +++ b/app/Controller/Webhook.php @@ -39,19 +39,4 @@ class Webhook extends Base $this->response->text('FAILED'); } - - /** - * Handle Gitlab webhooks - * - * @access public - */ - public function gitlab() - { - $this->checkWebhookToken(); - - $this->gitlabWebhook->setProjectId($this->request->getIntegerParam('project_id')); - $result = $this->gitlabWebhook->parsePayload($this->request->getJson()); - - echo $result ? 'PARSED' : 'IGNORED'; - } } diff --git a/app/Core/Base.php b/app/Core/Base.php index bbc51c50..1eef3cf7 100644 --- a/app/Core/Base.php +++ b/app/Core/Base.php @@ -45,7 +45,6 @@ use Pimple\Container; * @property \Kanboard\Core\Lexer $lexer * @property \Kanboard\Core\Paginator $paginator * @property \Kanboard\Core\Template $template - * @property \Kanboard\Integration\GitlabWebhook $gitlabWebhook * @property \Kanboard\Formatter\ProjectGanttFormatter $projectGanttFormatter * @property \Kanboard\Formatter\TaskFilterGanttFormatter $taskFilterGanttFormatter * @property \Kanboard\Formatter\TaskFilterAutoCompleteFormatter $taskFilterAutoCompleteFormatter diff --git a/app/Core/Event/EventManager.php b/app/Core/Event/EventManager.php index 34a70900..8d76bfcb 100644 --- a/app/Core/Event/EventManager.php +++ b/app/Core/Event/EventManager.php @@ -2,7 +2,6 @@ namespace Kanboard\Core\Event; -use Kanboard\Integration\GitlabWebhook; use Kanboard\Model\Task; use Kanboard\Model\TaskLink; @@ -53,11 +52,6 @@ class EventManager Task::EVENT_CLOSE => t('Closing a task'), Task::EVENT_CREATE_UPDATE => t('Task creation or modification'), Task::EVENT_ASSIGNEE_CHANGE => t('Task assignee change'), - GitlabWebhook::EVENT_COMMIT => t('Gitlab commit received'), - GitlabWebhook::EVENT_ISSUE_OPENED => t('Gitlab issue opened'), - GitlabWebhook::EVENT_ISSUE_REOPENED => t('Gitlab issue reopened'), - GitlabWebhook::EVENT_ISSUE_CLOSED => t('Gitlab issue closed'), - GitlabWebhook::EVENT_ISSUE_COMMENT => t('Gitlab issue comment created'), ); $events = array_merge($events, $this->events); diff --git a/app/Integration/GitlabWebhook.php b/app/Integration/GitlabWebhook.php deleted file mode 100644 index 5e0aa59d..00000000 --- a/app/Integration/GitlabWebhook.php +++ /dev/null @@ -1,298 +0,0 @@ -project_id = $project_id; - } - - /** - * Parse events - * - * @access public - * @param array $payload Gitlab event - * @return boolean - */ - public function parsePayload(array $payload) - { - switch ($this->getType($payload)) { - case self::TYPE_PUSH: - return $this->handlePushEvent($payload); - case self::TYPE_ISSUE; - return $this->handleIssueEvent($payload); - case self::TYPE_COMMENT; - return $this->handleCommentEvent($payload); - } - - return false; - } - - /** - * Get event type - * - * @access public - * @param array $payload Gitlab event - * @return string - */ - public function getType(array $payload) - { - if (empty($payload['object_kind'])) { - return ''; - } - - switch ($payload['object_kind']) { - case 'issue': - return self::TYPE_ISSUE; - case 'note': - return self::TYPE_COMMENT; - case 'push': - return self::TYPE_PUSH; - default: - return ''; - } - } - - /** - * Parse push event - * - * @access public - * @param array $payload Gitlab event - * @return boolean - */ - public function handlePushEvent(array $payload) - { - foreach ($payload['commits'] as $commit) { - $this->handleCommit($commit); - } - - return true; - } - - /** - * Parse commit - * - * @access public - * @param array $commit Gitlab commit - * @return boolean - */ - public function handleCommit(array $commit) - { - $task_id = $this->task->getTaskIdFromText($commit['message']); - - if (empty($task_id)) { - return false; - } - - $task = $this->taskFinder->getById($task_id); - - if (empty($task)) { - return false; - } - - if ($task['project_id'] != $this->project_id) { - return false; - } - - $this->container['dispatcher']->dispatch( - self::EVENT_COMMIT, - new GenericEvent(array( - 'task_id' => $task_id, - 'commit_message' => $commit['message'], - 'commit_url' => $commit['url'], - 'comment' => $commit['message']."\n\n[".t('Commit made by @%s on Gitlab', $commit['author']['name']).']('.$commit['url'].')' - ) + $task) - ); - - return true; - } - - /** - * Parse issue event - * - * @access public - * @param array $payload Gitlab event - * @return boolean - */ - public function handleIssueEvent(array $payload) - { - switch ($payload['object_attributes']['action']) { - case 'open': - return $this->handleIssueOpened($payload['object_attributes']); - case 'close': - return $this->handleIssueClosed($payload['object_attributes']); - case 'reopen': - return $this->handleIssueReopened($payload['object_attributes']); - } - - return false; - } - - /** - * Handle new issues - * - * @access public - * @param array $issue Issue data - * @return boolean - */ - public function handleIssueOpened(array $issue) - { - $event = array( - 'project_id' => $this->project_id, - 'reference' => $issue['id'], - 'title' => $issue['title'], - 'description' => $issue['description']."\n\n[".t('Gitlab Issue').']('.$issue['url'].')', - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_OPENED, - new GenericEvent($event) - ); - - return true; - } - - /** - * Handle issue reopening - * - * @access public - * @param array $issue Issue data - * @return boolean - */ - public function handleIssueReopened(array $issue) - { - $task = $this->taskFinder->getByReference($this->project_id, $issue['id']); - - if (! empty($task)) { - $event = array( - 'project_id' => $this->project_id, - 'task_id' => $task['id'], - 'reference' => $issue['id'], - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_REOPENED, - new GenericEvent($event) - ); - - return true; - } - - return false; - } - - - /** - * Handle issue closing - * - * @access public - * @param array $issue Issue data - * @return boolean - */ - public function handleIssueClosed(array $issue) - { - $task = $this->taskFinder->getByReference($this->project_id, $issue['id']); - - if (! empty($task)) { - $event = array( - 'project_id' => $this->project_id, - 'task_id' => $task['id'], - 'reference' => $issue['id'], - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_CLOSED, - new GenericEvent($event) - ); - - return true; - } - - return false; - } - - /** - * Parse comment issue events - * - * @access public - * @param array $payload Event data - * @return boolean - */ - public function handleCommentEvent(array $payload) - { - if (! isset($payload['issue'])) { - return false; - } - - $task = $this->taskFinder->getByReference($this->project_id, $payload['issue']['id']); - - if (! empty($task)) { - $user = $this->user->getByUsername($payload['user']['username']); - - if (! empty($user) && ! $this->projectPermission->isAssignable($this->project_id, $user['id'])) { - $user = array(); - } - - $event = array( - 'project_id' => $this->project_id, - 'reference' => $payload['object_attributes']['id'], - 'comment' => $payload['object_attributes']['note']."\n\n[".t('By @%s on Gitlab', $payload['user']['username']).']('.$payload['object_attributes']['url'].')', - 'user_id' => ! empty($user) ? $user['id'] : 0, - 'task_id' => $task['id'], - ); - - $this->container['dispatcher']->dispatch( - self::EVENT_ISSUE_COMMENT, - new GenericEvent($event) - ); - - return true; - } - - return false; - } -} diff --git a/app/Locale/bs_BA/translations.php b/app/Locale/bs_BA/translations.php index 50b17c1b..777810cd 100644 --- a/app/Locale/bs_BA/translations.php +++ b/app/Locale/bs_BA/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Swimline traka je uspješno kreirana.', 'Example: "Bug, Feature Request, Improvement"' => 'Npr: "Greška, Zahtjev za izmjenama, Poboljšanje"', 'Default categories for new projects (Comma-separated)' => 'Podrazumijevane kategorije za novi projekat', - 'Gitlab commit received' => 'Gitlab: commit dobijen', - 'Gitlab issue opened' => 'Gitlab: problem otvoren', - 'Gitlab issue closed' => 'Gitlab: problem zatvoren', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Pomoc na Gitlab webhooks', 'Integrations' => 'Integracije', 'Integration with third-party services' => 'Integracija sa uslugama vanjskih servisa', - 'Gitlab Issue' => 'Gitlab problemi', 'Subtask Id' => 'ID pod-zadatka', 'Subtasks' => 'Pod-zadaci', 'Subtasks Export' => 'Izvoz pod-zadataka', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Vanjski korisnik', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Vanjski korisnik ne čuva šifru u Kanboard bazi, npr: LDAP, Google i Github korisnički računi.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Ako ste označili kvadratić "Zabrani prijavnu formu", unos pristupnih podataka u prijavnoj formi će biti ignorisan.', - 'By @%s on Gitlab' => 'Od @%s s Gitlab-om', - 'Gitlab issue comment created' => 'Gitlab: dodan komentar za problem', 'New remote user' => 'Novi vanjski korisnik', 'New local user' => 'Novi lokalni korisnik', 'Default task color' => 'Podrazumijevana boja zadatka', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/cs_CZ/translations.php b/app/Locale/cs_CZ/translations.php index 8baba251..70ea873b 100644 --- a/app/Locale/cs_CZ/translations.php +++ b/app/Locale/cs_CZ/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Die Swimlane wurde erfolgreich angelegt.', 'Example: "Bug, Feature Request, Improvement"' => 'Beispiel: "Bug, Funktionswünsche, Verbesserung"', 'Default categories for new projects (Comma-separated)' => 'Výchozí kategorie pro nové projekty (oddělené čárkou)', - 'Gitlab commit received' => 'Gitlab commit erhalten', - 'Gitlab issue opened' => 'Gitlab Fehler eröffnet', - 'Gitlab issue closed' => 'Gitlab Fehler geschlossen', - 'Gitlab webhooks' => 'Gitlab Webhook', - 'Help on Gitlab webhooks' => 'Hilfe für Gitlab Webhooks', 'Integrations' => 'Integrace', 'Integration with third-party services' => 'Integration von Fremdleistungen', - 'Gitlab Issue' => 'Gitlab Fehler', 'Subtask Id' => 'Dílčí úkol Id', 'Subtasks' => 'Dílčí úkoly', 'Subtasks Export' => 'Export dílčích úkolů', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Vzdálený uživatel', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Hesla vzdáleným uživatelům se neukládají do databáze Kanboard. Naříklad: LDAP, Google a Github účty.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Pokud zaškrtnete políčko "Zakázat přihlašovací formulář", budou pověření zadané do přihlašovacího formuláře ignorovány.', - 'By @%s on Gitlab' => 'uživatelem @%s na Gitlab', - 'Gitlab issue comment created' => 'Vytvořen komentář problému na Gitlab', 'New remote user' => 'Nový vzdálený uživatel', 'New local user' => 'Nový lokální uživatel', 'Default task color' => 'Výchozí barva úkolu', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/da_DK/translations.php b/app/Locale/da_DK/translations.php index dd531abb..37504d66 100644 --- a/app/Locale/da_DK/translations.php +++ b/app/Locale/da_DK/translations.php @@ -543,14 +543,8 @@ return array( // 'Your swimlane have been created successfully.' => '', // 'Example: "Bug, Feature Request, Improvement"' => '', // 'Default categories for new projects (Comma-separated)' => '', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', // 'Integrations' => '', // 'Integration with third-party services' => '', - // 'Gitlab Issue' => '', // 'Subtask Id' => '', // 'Subtasks' => '', // 'Subtasks Export' => '', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/de_DE/translations.php b/app/Locale/de_DE/translations.php index 263e0421..69efb309 100644 --- a/app/Locale/de_DE/translations.php +++ b/app/Locale/de_DE/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Die Swimlane wurde erfolgreich angelegt.', 'Example: "Bug, Feature Request, Improvement"' => 'Beispiel: "Bug, Funktionswünsche, Verbesserung"', 'Default categories for new projects (Comma-separated)' => 'Standard-Kategorien für neue Projekte (Komma-getrennt)', - 'Gitlab commit received' => 'Gitlab-Commit erhalten', - 'Gitlab issue opened' => 'Gitlab-Issue eröffnet', - 'Gitlab issue closed' => 'Gitlab-Issue geschlossen', - 'Gitlab webhooks' => 'Gitlab-Webhook', - 'Help on Gitlab webhooks' => 'Hilfe für Gitlab-Webhooks', 'Integrations' => 'Integration', 'Integration with third-party services' => 'Integration von externen Diensten', - 'Gitlab Issue' => 'Gitlab-Issue', 'Subtask Id' => 'Teilaufgaben-ID', 'Subtasks' => 'Teilaufgaben', 'Subtasks Export' => 'Export von Teilaufgaben', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Remote-Benutzer', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Remote-Benutzer haben kein Passwort in der Kanboard Datenbank, Beispiel LDAP, Goole und Github Accounts', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Wenn die Box "Verbiete Login-Formular" angeschaltet ist, werden Eingaben in das Login Formular ignoriert.', - 'By @%s on Gitlab' => 'Durch @%s auf Gitlab', - 'Gitlab issue comment created' => 'Gitlab Ticket Kommentar erstellt', 'New remote user' => 'Neuer Remote-Benutzer', 'New local user' => 'Neuer lokaler Benutzer', 'Default task color' => 'Voreingestellte Aufgabenfarbe', @@ -1047,7 +1039,6 @@ return array( 'Project Manager' => 'Projekt Manager', 'Project Member' => 'Projekt Mitglied', 'Project Viewer' => 'Projekt Betrachter', - 'Gitlab issue reopened' => 'Gitlab Thema wiedereröffnet', 'Your account is locked for %d minutes' => 'Ihr Zugang wurde für %d Minuten gesperrt', 'Invalid captcha' => 'Ungültiges Captcha', 'The name must be unique' => 'Der Name muss eindeutig sein', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/es_ES/translations.php b/app/Locale/es_ES/translations.php index aa08e35c..e28e1757 100644 --- a/app/Locale/es_ES/translations.php +++ b/app/Locale/es_ES/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Su calle ha sido creada correctamente', 'Example: "Bug, Feature Request, Improvement"' => 'Ejemplo: "Error, Solicitud de característica, Mejora', 'Default categories for new projects (Comma-separated)' => 'Categorías por defecto para nuevos proyectos (separadas por comas)', - 'Gitlab commit received' => 'Recibido envío desde Gitlab', - 'Gitlab issue opened' => 'Abierto asunto de Gitlab', - 'Gitlab issue closed' => 'Cerrado asunto de Gitlab', - 'Gitlab webhooks' => 'Disparadores Web (Webhooks) de Gitlab', - 'Help on Gitlab webhooks' => 'Ayuda sobre Disparadores Web (Webhooks) de Gitlab', 'Integrations' => 'Integraciones', 'Integration with third-party services' => 'Integración con servicios de terceros', - 'Gitlab Issue' => 'Asunto Gitlab', 'Subtask Id' => 'Id de Subtarea', 'Subtasks' => 'Subtareas', 'Subtasks Export' => 'Exportación de Subtareas', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Usuario remoto', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Los usuarios remotos no almacenan sus contraseñas en la base de datos Kanboard, por ejemplo: cuentas de LDAP, Google y Github', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Si marcas la caja de edición "Desactivar formulario de ingreso", se ignoran las credenciales entradas en el formulario de ingreso.', - 'By @%s on Gitlab' => 'Por @%s en Gitlab', - 'Gitlab issue comment created' => 'Creado comentario de asunto de Gitlab', 'New remote user' => 'Nuevo usuario remoto', 'New local user' => 'Nuevo usuario local', 'Default task color' => 'Color por defecto de tarea', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/fi_FI/translations.php b/app/Locale/fi_FI/translations.php index e1a14749..76f312fd 100644 --- a/app/Locale/fi_FI/translations.php +++ b/app/Locale/fi_FI/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Kaista luotu onnistuneesti.', 'Example: "Bug, Feature Request, Improvement"' => 'Esimerkiksi: "Bugit, Ominaisuuspyynnöt, Parannukset"', 'Default categories for new projects (Comma-separated)' => 'Oletuskategoriat uusille projekteille (pilkuin eroteltu)', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', // 'Integrations' => '', // 'Integration with third-party services' => '', - // 'Gitlab Issue' => '', // 'Subtask Id' => '', // 'Subtasks' => '', // 'Subtasks Export' => '', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/fr_FR/translations.php b/app/Locale/fr_FR/translations.php index f974584f..f2e7dda2 100644 --- a/app/Locale/fr_FR/translations.php +++ b/app/Locale/fr_FR/translations.php @@ -545,14 +545,8 @@ return array( 'Your swimlane have been created successfully.' => 'Votre swimlane a été créée avec succès.', 'Example: "Bug, Feature Request, Improvement"' => 'Exemple: « Incident, Demande de fonctionnalité, Amélioration »', 'Default categories for new projects (Comma-separated)' => 'Catégories par défaut pour les nouveaux projets (séparation par des virgules)', - 'Gitlab commit received' => 'Commit reçu via Gitlab', - 'Gitlab issue opened' => 'Ouverture d\'un ticket sur Gitlab', - 'Gitlab issue closed' => 'Fermeture d\'un ticket sur Gitlab', - 'Gitlab webhooks' => 'Webhook Gitlab', - 'Help on Gitlab webhooks' => 'Aide sur les webhooks Gitlab', 'Integrations' => 'Intégrations', 'Integration with third-party services' => 'Intégration avec des services externes', - 'Gitlab Issue' => 'Ticket Gitlab', 'Subtask Id' => 'Identifiant de la sous-tâche', 'Subtasks' => 'Sous-tâches', 'Subtasks Export' => 'Exportation des sous-tâches', @@ -872,8 +866,6 @@ return array( 'Remote user' => 'Utilisateur distant', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Les utilisateurs distants ne stockent pas leur mot de passe dans la base de données de Kanboard, exemples : comptes LDAP, Github ou Google.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Si vous cochez la case « Interdire le formulaire d\'authentification », les identifiants entrés dans le formulaire d\'authentification seront ignorés.', - 'By @%s on Gitlab' => 'Par @%s sur Gitlab', - 'Gitlab issue comment created' => 'Commentaire créé sur un ticket Gitlab', 'New remote user' => 'Créer un utilisateur distant', 'New local user' => 'Créer un utilisateur local', 'Default task color' => 'Couleur par défaut des tâches', @@ -1050,7 +1042,6 @@ return array( 'Project Manager' => 'Chef de projet', 'Project Member' => 'Membre du projet', 'Project Viewer' => 'Visualiseur de projet', - 'Gitlab issue reopened' => 'Ticket Gitlab rouvert', 'Your account is locked for %d minutes' => 'Votre compte est vérouillé pour %d minutes', 'Invalid captcha' => 'Captcha invalid', 'The name must be unique' => 'Le nom doit être unique', @@ -1097,4 +1088,5 @@ return array( 'Two-Factor Provider: ' => 'Fournisseur d\'authentification à deux facteurs : ', 'Disable two-factor authentication' => 'Désactiver l\'authentification à deux-facteurs', 'Enable two-factor authentication' => 'Activer l\'authentification à deux-facteurs', + 'There is no integration registered at the moment.' => 'Il n\'y a aucune intégration enregistrée pour le moment.', ); diff --git a/app/Locale/hu_HU/translations.php b/app/Locale/hu_HU/translations.php index 392ead6c..54c4ba40 100644 --- a/app/Locale/hu_HU/translations.php +++ b/app/Locale/hu_HU/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'A folyamat sikeresen létrehozva.', 'Example: "Bug, Feature Request, Improvement"' => 'Például: Hiba, Új funkció, Fejlesztés', 'Default categories for new projects (Comma-separated)' => 'Alapértelmezett kategóriák az új projektekben (Vesszővel elválasztva)', - 'Gitlab commit received' => 'Gitlab commit érkezett', - 'Gitlab issue opened' => 'Gitlab issue nyitás', - 'Gitlab issue closed' => 'Gitlab issue zárás', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Gitlab webhooks súgó', 'Integrations' => 'Integráció', 'Integration with third-party services' => 'Integráció harmadik féllel', - 'Gitlab Issue' => 'Gitlab issue', 'Subtask Id' => 'Részfeladat id', 'Subtasks' => 'Részfeladatok', 'Subtasks Export' => 'Részfeladat exportálás', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/id_ID/translations.php b/app/Locale/id_ID/translations.php index 9640abfb..ab296437 100644 --- a/app/Locale/id_ID/translations.php +++ b/app/Locale/id_ID/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Swimlane anda berhasil dibuat.', 'Example: "Bug, Feature Request, Improvement"' => 'Contoh: « Insiden, Permintaan Fitur, Perbaikan »', 'Default categories for new projects (Comma-separated)' => 'Standar kategori untuk proyek baru (dipisahkan dengan koma)', - 'Gitlab commit received' => 'Menerima komit Gitlab', - 'Gitlab issue opened' => 'Tiket Gitlab dibuka', - 'Gitlab issue closed' => 'Tiket Gitlab ditutup', - 'Gitlab webhooks' => 'Webhook Gitlab', - 'Help on Gitlab webhooks' => 'Bantuan pada webhook Gitlab', 'Integrations' => 'Integrasi', 'Integration with third-party services' => 'Integrasi dengan layanan pihak ketiga', - 'Gitlab Issue' => 'Tiket Gitlab', 'Subtask Id' => 'Id Subtugas', 'Subtasks' => 'Subtugas', 'Subtasks Export' => 'Ekspor Subtugas', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Pengguna jauh', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Pengguna jauh tidak menyimpan kata sandi mereka dalam basis data Kanboard, contoh: akun LDAP, Google dan Github.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Jika anda mencentang kotak "Larang formulir login", kredensial masuk ke formulis login akan diabaikan.', - 'By @%s on Gitlab' => 'Dengan @%s pada Gitlab', - 'Gitlab issue comment created' => 'Komentar dibuat pada tiket Gitlab', 'New remote user' => 'Pengguna baru jauh', 'New local user' => 'Pengguna baru lokal', 'Default task color' => 'Standar warna tugas', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/it_IT/translations.php b/app/Locale/it_IT/translations.php index 81d1853f..7d8df85f 100644 --- a/app/Locale/it_IT/translations.php +++ b/app/Locale/it_IT/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'La sua corsia è stata creata con successo', 'Example: "Bug, Feature Request, Improvement"' => 'Esempio: "Bug, Richiesta di Funzioni, Migliorie"', 'Default categories for new projects (Comma-separated)' => 'Categorie di default per i progetti (Separati da virgola)', - 'Gitlab commit received' => 'Commit ricevuto da Gitlab', - 'Gitlab issue opened' => 'Issue di Gitlab aperta', - 'Gitlab issue closed' => 'Issue di Gitlab chiusa', - 'Gitlab webhooks' => 'Webhooks di Gitlab', - 'Help on Gitlab webhooks' => 'Guida ai Webhooks di Gitlab', 'Integrations' => 'Integrazioni', 'Integration with third-party services' => 'Integrazione con servizi di terze parti', - 'Gitlab Issue' => 'Issue di Gitlab', 'Subtask Id' => 'Id del sotto-compito', 'Subtasks' => 'Sotto-compiti', 'Subtasks Export' => 'Esporta sotto-compiti', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/ja_JP/translations.php b/app/Locale/ja_JP/translations.php index 3b24f224..f1d20c49 100644 --- a/app/Locale/ja_JP/translations.php +++ b/app/Locale/ja_JP/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'スイムレーンが作成されました。', 'Example: "Bug, Feature Request, Improvement"' => '例: バグ, 機能, 改善', 'Default categories for new projects (Comma-separated)' => '新しいプロジェクトのデフォルトカテゴリー (コンマ区切り)', - 'Gitlab commit received' => 'Gitlab コミットを受診しました', - 'Gitlab issue opened' => 'Gitlab Issue がオープンされました', - 'Gitlab issue closed' => 'Gitlab Issue がクローズされました', - 'Gitlab webhooks' => 'Gitlab Webhooks', - 'Help on Gitlab webhooks' => 'Gitlab Webhooks のヘルプ', 'Integrations' => '連携', 'Integration with third-party services' => 'サードパーティサービスとの連携', - 'Gitlab Issue' => 'Gitlab Issue', 'Subtask Id' => 'サブタスク Id', 'Subtasks' => 'サブタスク', 'Subtasks Export' => 'サブタスクの出力', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/nb_NO/translations.php b/app/Locale/nb_NO/translations.php index 75631126..67dac98c 100644 --- a/app/Locale/nb_NO/translations.php +++ b/app/Locale/nb_NO/translations.php @@ -543,14 +543,8 @@ return array( // 'Your swimlane have been created successfully.' => '', // 'Example: "Bug, Feature Request, Improvement"' => '', // 'Default categories for new projects (Comma-separated)' => '', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', 'Integrations' => 'Integrasjoner', 'Integration with third-party services' => 'Integrasjoner med tredje-parts tjenester', - // 'Gitlab Issue' => '', 'Subtask Id' => 'Deloppgave ID', 'Subtasks' => 'Deloppgaver', 'Subtasks Export' => 'Eksporter deloppgaver', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', 'New remote user' => 'Ny eksternbruker', 'New local user' => 'Ny internbruker', 'Default task color' => 'Standard oppgavefarge', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/nl_NL/translations.php b/app/Locale/nl_NL/translations.php index 5e1d2960..c52c20ea 100644 --- a/app/Locale/nl_NL/translations.php +++ b/app/Locale/nl_NL/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Swimlane succesvol aangemaakt.', 'Example: "Bug, Feature Request, Improvement"' => 'Voorbeeld: « Bug, Feature Request, Improvement »', 'Default categories for new projects (Comma-separated)' => 'Standaard categorieën voor nieuwe projecten (komma gescheiden)', - 'Gitlab commit received' => 'Gitlab commir ontvangen', - 'Gitlab issue opened' => 'Gitlab issue geopend', - 'Gitlab issue closed' => 'Gitlab issue gesloten', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Hulp bij Gitlab webhooks', 'Integrations' => 'Integraties', 'Integration with third-party services' => 'Integratie met derde-partij-services', - 'Gitlab Issue' => 'Gitlab issue', 'Subtask Id' => 'Subtaak id', 'Subtasks' => 'Subtaken', 'Subtasks Export' => 'Subtaken exporteren', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/pl_PL/translations.php b/app/Locale/pl_PL/translations.php index 253e19f6..dc95fbe1 100644 --- a/app/Locale/pl_PL/translations.php +++ b/app/Locale/pl_PL/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Proces tworzony pomyślnie.', 'Example: "Bug, Feature Request, Improvement"' => 'Przykład: "Błąd, Żądanie Funkcjonalności, Udoskonalenia"', 'Default categories for new projects (Comma-separated)' => 'Domyślne kategorie dla nowych projektów (oddzielone przecinkiem)', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', 'Integrations' => 'Integracje', 'Integration with third-party services' => 'Integracja z usługami firm trzecich', - // 'Gitlab Issue' => '', 'Subtask Id' => 'ID pod-zadania', 'Subtasks' => 'Pod-zadania', 'Subtasks Export' => 'Eksport pod-zadań', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', 'New remote user' => 'Nowy użytkownik zdalny', 'New local user' => 'Nowy użytkownik lokalny', 'Default task color' => 'Domyślny kolor zadań', @@ -1047,7 +1039,6 @@ return array( 'Project Manager' => 'Menedżer projektu', 'Project Member' => 'Uczestnik projektu', 'Project Viewer' => 'Obserwator projektu', - // 'Gitlab issue reopened' => '', 'Your account is locked for %d minutes' => 'Twoje konto zostało zablokowane na %d minut', 'Invalid captcha' => 'Błędny kod z obrazka (captcha)', 'The name must be unique' => 'Nazwa musi być unikatowa', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/pt_BR/translations.php b/app/Locale/pt_BR/translations.php index ac063b16..7b291f26 100644 --- a/app/Locale/pt_BR/translations.php +++ b/app/Locale/pt_BR/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Sua swimlane foi criada com sucesso.', 'Example: "Bug, Feature Request, Improvement"' => 'Exemplo: "Bug, Solicitação de Recurso, Melhoria"', 'Default categories for new projects (Comma-separated)' => 'Categorias padrões para novos projetos (separadas por vírgula)', - 'Gitlab commit received' => 'Gitlab commit received', - 'Gitlab issue opened' => 'Gitlab issue opened', - 'Gitlab issue closed' => 'Gitlab issue closed', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Ajuda sobre os webhooks do GitLab', 'Integrations' => 'Integrações', 'Integration with third-party services' => 'Integração com serviços de terceiros', - 'Gitlab Issue' => 'Gitlab Issue', 'Subtask Id' => 'ID da subtarefa', 'Subtasks' => 'Subtarefas', 'Subtasks Export' => 'Exportar subtarefas', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Usuário remoto', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Os usuários remotos não conservam as suas senhas no banco de dados Kanboard, exemplos: contas LDAP, Github ou Google.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Se você marcar "Interdir o formulário de autenticação", os identificadores entrados no formulário de login serão ignorado.', - 'By @%s on Gitlab' => 'Por @%s no Gitlab', - 'Gitlab issue comment created' => 'Comentário criado em um bilhete Gitlab', 'New remote user' => 'Criar um usuário remoto', 'New local user' => 'Criar um usuário local', 'Default task color' => 'Cor padrão para as tarefas', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/pt_PT/translations.php b/app/Locale/pt_PT/translations.php index fec3b724..44003b1b 100644 --- a/app/Locale/pt_PT/translations.php +++ b/app/Locale/pt_PT/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Seu swimlane foi criado com sucesso.', 'Example: "Bug, Feature Request, Improvement"' => 'Exemplo: "Bug, Feature Request, Improvement"', 'Default categories for new projects (Comma-separated)' => 'Categorias padrão para novos projectos (Separadas por vírgula)', - 'Gitlab commit received' => 'Commit recebido do Gitlab', - 'Gitlab issue opened' => 'Problema aberto no Gitlab', - 'Gitlab issue closed' => 'Problema fechado no Gitlab', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Ajuda sobre Gitlab webhooks', 'Integrations' => 'Integrações', 'Integration with third-party services' => 'Integração com serviços de terceiros', - 'Gitlab Issue' => 'Problema Gitlab', 'Subtask Id' => 'ID da subtarefa', 'Subtasks' => 'Subtarefas', 'Subtasks Export' => 'Exportar subtarefas', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Utilizador remoto', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Utilizadores remotos não guardam a password na base de dados do Kanboard, por exemplo: LDAP, contas do Google e Github.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Se activar a opção "Desactivar login", as credenciais digitadas no login serão ignoradas.', - 'By @%s on Gitlab' => 'Por @%s no Gitlab', - 'Gitlab issue comment created' => 'Comentário a problema no Gitlab adicionado', 'New remote user' => 'Novo utilizador remoto', 'New local user' => 'Novo utilizador local', 'Default task color' => 'Cor de tarefa por defeito', @@ -1047,7 +1039,6 @@ return array( 'Project Manager' => 'Gestor de Projecto', 'Project Member' => 'Membro de Projecto', 'Project Viewer' => 'Visualizador de Projecto', - 'Gitlab issue reopened' => 'Problema Gitlab reaberto', 'Your account is locked for %d minutes' => 'A sua conta está bloqueada por %d minutos', 'Invalid captcha' => 'Captcha inválido', 'The name must be unique' => 'O nome deve ser único', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/ru_RU/translations.php b/app/Locale/ru_RU/translations.php index a8066115..4ad5b593 100644 --- a/app/Locale/ru_RU/translations.php +++ b/app/Locale/ru_RU/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Ваша дорожка была успешно создан.', 'Example: "Bug, Feature Request, Improvement"' => 'Например: "Баг, Фича, Улучшение"', 'Default categories for new projects (Comma-separated)' => 'Стандартные категории для нового проекта (разделяются запятыми)', - 'Gitlab commit received' => 'Получен коммит с Gitlab', - 'Gitlab issue opened' => 'Gitlab вопрос открыт', - 'Gitlab issue closed' => 'Gitlab вопрос закрыт', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Помощь по Gitlab webhooks', 'Integrations' => 'Интеграции', 'Integration with third-party services' => 'Интеграция со сторонними сервисами', - 'Gitlab Issue' => 'Gitlab вопрос', 'Subtask Id' => 'Id подзадачи', 'Subtasks' => 'Подзадачи', 'Subtasks Export' => 'Экспортировать подзадачи', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Удаленный пользователь', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Учетные данные для входа через LDAP, Google и Github не будут сохранены в Kanboard.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Если вы установите флажок "Запретить форму входа", учетные данные, введенные в форму входа будет игнорироваться.', - 'By @%s on Gitlab' => 'От @%s на Gitlab', - 'Gitlab issue comment created' => 'Был создан комментарий к задаче на Gitlab', 'New remote user' => 'Новый удаленный пользователь', 'New local user' => 'Новый локальный пользователь', 'Default task color' => 'Стандартные цвета задач', @@ -1047,7 +1039,6 @@ return array( 'Project Manager' => 'Менеджер проекта', 'Project Member' => 'Участник проекта', 'Project Viewer' => 'Наблюдатель проекта', - 'Gitlab issue reopened' => 'Gitlab вопрос переоткрыт', 'Your account is locked for %d minutes' => 'Ваш аккаунт заблокирован на %d минут', 'Invalid captcha' => 'Неверный код подтверждения', 'The name must be unique' => 'Имя должно быть уникальным', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/sr_Latn_RS/translations.php b/app/Locale/sr_Latn_RS/translations.php index b59e2e51..07efed98 100644 --- a/app/Locale/sr_Latn_RS/translations.php +++ b/app/Locale/sr_Latn_RS/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Razdelnik je uspešno kreiran.', 'Example: "Bug, Feature Request, Improvement"' => 'Npr: "Greška, Zahtev za izmenama, Poboljšanje"', 'Default categories for new projects (Comma-separated)' => 'Osnovne kategorije za projekat', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', 'Integrations' => 'Integracje', 'Integration with third-party services' => 'Integracja sa uslugama spoljnih servisa', - // 'Gitlab Issue' => '', 'Subtask Id' => 'ID pod-zadania', 'Subtasks' => 'Pod-zadataka', 'Subtasks Export' => 'Eksport pod-zadań', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/sv_SE/translations.php b/app/Locale/sv_SE/translations.php index bf6ee199..46159d8b 100644 --- a/app/Locale/sv_SE/translations.php +++ b/app/Locale/sv_SE/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Din swimlane har skapats', 'Example: "Bug, Feature Request, Improvement"' => 'Exempel: "Bug, ny funktionalitet, förbättringar"', 'Default categories for new projects (Comma-separated)' => 'Standardkategorier för nya projekt (komma-separerade)', - 'Gitlab commit received' => 'Gitlab bidrag mottaget', - 'Gitlab issue opened' => 'Gitlab fråga öppnad', - 'Gitlab issue closed' => 'Gitlab fråga stängd', - 'Gitlab webhooks' => 'Gitlab webhooks', - 'Help on Gitlab webhooks' => 'Hjälp för Gitlab webhooks', 'Integrations' => 'Integrationer', 'Integration with third-party services' => 'Integration med tjänst från tredjepart', - 'Gitlab Issue' => 'Gitlab fråga', 'Subtask Id' => 'Deluppgifts-ID', 'Subtasks' => 'Deluppgift', 'Subtasks Export' => 'Export av deluppgifter', @@ -870,8 +864,6 @@ return array( 'Remote user' => 'Extern användare', 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => 'Externa användares lösenord lagras inte i Kanboard-databasen, exempel: LDAP, Google och Github-konton.', 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => 'Om du aktiverar boxen "Tillåt inte loginformulär" kommer inloggningsuppgifter i formuläret att ignoreras.', - 'By @%s on Gitlab' => 'Av @%s på Gitlab', - 'Gitlab issue comment created' => 'Gitlab frågekommentar skapad', 'New remote user' => 'Ny extern användare', 'New local user' => 'Ny lokal användare', 'Default task color' => 'Standardfärg för uppgifter', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/th_TH/translations.php b/app/Locale/th_TH/translations.php index 81946540..0706163d 100644 --- a/app/Locale/th_TH/translations.php +++ b/app/Locale/th_TH/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'สวิมเลนของคุณถูกสร้างเรียบร้อยแล้ว', 'Example: "Bug, Feature Request, Improvement"' => 'ตัวอย่าง: "Bug, Feature Request, Improvement"', 'Default categories for new projects (Comma-separated)' => 'ค่าเริ่มต้นกลุ่มสำหรับโปรเจคใหม่ (Comma-separated)', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', 'Integrations' => 'การใช้ร่วมกัน', 'Integration with third-party services' => 'การใช้งานร่วมกับบริการ third-party', - // 'Gitlab Issue' => '', 'Subtask Id' => 'รหัสงานย่อย', 'Subtasks' => 'งานย่อย', 'Subtasks Export' => 'ส่งออก งานย่อย', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/tr_TR/translations.php b/app/Locale/tr_TR/translations.php index 10472aad..3b576485 100644 --- a/app/Locale/tr_TR/translations.php +++ b/app/Locale/tr_TR/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => 'Kulvar başarıyla oluşturuldu.', 'Example: "Bug, Feature Request, Improvement"' => 'Örnek: "Sorun, Özellik talebi, İyileştirme"', 'Default categories for new projects (Comma-separated)' => 'Yeni projeler için varsayılan kategoriler (Virgül ile ayrılmış)', - // 'Gitlab commit received' => '', - // 'Gitlab issue opened' => '', - // 'Gitlab issue closed' => '', - // 'Gitlab webhooks' => '', - // 'Help on Gitlab webhooks' => '', 'Integrations' => 'Entegrasyon', 'Integration with third-party services' => 'Dış servislerle entegrasyon', - // 'Gitlab Issue' => '', 'Subtask Id' => 'Alt görev No:', 'Subtasks' => 'Alt görevler', 'Subtasks Export' => 'Alt görevleri dışa aktar', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', // 'Default task color' => '', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/Locale/zh_CN/translations.php b/app/Locale/zh_CN/translations.php index a152748f..f5de4725 100644 --- a/app/Locale/zh_CN/translations.php +++ b/app/Locale/zh_CN/translations.php @@ -543,14 +543,8 @@ return array( 'Your swimlane have been created successfully.' => '已经成功创建泳道。', 'Example: "Bug, Feature Request, Improvement"' => '示例:“缺陷,功能需求,提升', 'Default categories for new projects (Comma-separated)' => '新项目的默认分类(用逗号分隔)', - 'Gitlab commit received' => '收到 Gitlab 提交', - 'Gitlab issue opened' => '开启 Gitlab 问题', - 'Gitlab issue closed' => '关闭 Gitlab 问题', - 'Gitlab webhooks' => 'Gitlab 网络钩子', - 'Help on Gitlab webhooks' => 'Gitlab 网络钩子帮助', 'Integrations' => '整合', 'Integration with third-party services' => '与第三方服务进行整合', - 'Gitlab Issue' => 'Gitlab 问题', 'Subtask Id' => '子任务 Id', 'Subtasks' => '子任务', 'Subtasks Export' => '子任务导出', @@ -870,8 +864,6 @@ return array( // 'Remote user' => '', // 'Remote users do not store their password in Kanboard database, examples: LDAP, Google and Github accounts.' => '', // 'If you check the box "Disallow login form", credentials entered in the login form will be ignored.' => '', - // 'By @%s on Gitlab' => '', - // 'Gitlab issue comment created' => '', // 'New remote user' => '', // 'New local user' => '', 'Default task color' => '默认任务颜色', @@ -1047,7 +1039,6 @@ return array( // 'Project Manager' => '', // 'Project Member' => '', // 'Project Viewer' => '', - // 'Gitlab issue reopened' => '', // 'Your account is locked for %d minutes' => '', // 'Invalid captcha' => '', // 'The name must be unique' => '', @@ -1094,4 +1085,5 @@ return array( // 'Two-Factor Provider: ' => '', // 'Disable two-factor authentication' => '', // 'Enable two-factor authentication' => '', + // 'There is no integration registered at the moment.' => '', ); diff --git a/app/ServiceProvider/ClassProvider.php b/app/ServiceProvider/ClassProvider.php index f7cd466c..3f6aecc5 100644 --- a/app/ServiceProvider/ClassProvider.php +++ b/app/ServiceProvider/ClassProvider.php @@ -114,9 +114,6 @@ class ClassProvider implements ServiceProviderInterface 'UserSync', 'UserSession', 'UserProfile', - ), - 'Integration' => array( - 'GitlabWebhook', ) ); diff --git a/app/Template/project/integrations.php b/app/Template/project/integrations.php index 77b1b793..54720c69 100644 --- a/app/Template/project/integrations.php +++ b/app/Template/project/integrations.php @@ -5,11 +5,11 @@
form->csrf() ?> - hook->render('template:project:integrations', array('project' => $project, 'values' => $values, 'webhook_token' => $webhook_token)) ?> + hook->render('template:project:integrations', array('project' => $project, 'values' => $values, 'webhook_token' => $webhook_token)) ?> -

 

-
-
-

url->doc(t('Help on Gitlab webhooks'), 'gitlab-webhooks') ?>

-
+ +

+ + +
\ No newline at end of file diff --git a/doc/gitlab-webhooks.markdown b/doc/gitlab-webhooks.markdown deleted file mode 100644 index fec47c19..00000000 --- a/doc/gitlab-webhooks.markdown +++ /dev/null @@ -1,70 +0,0 @@ -Gitlab webhooks -=============== - -Gitlab events can be connected to Kanboard automatic actions. - -List of supported events ------------------------- - -- Gitlab commit received -- Gitlab issue opened -- Gitlab issue closed -- Gitlab issue comment created - -List of supported actions -------------------------- - -- Create a task from an external provider -- Close a task -- Create a comment from an external provider - -Configuration -------------- - -![Gitlab configuration](http://kanboard.net/screenshots/documentation/gitlab-webhooks.png) - -1. On Kanboard, go to the project settings and choose the section **Integrations** -2. Copy the Gitlab webhook url -3. On Gitlab, go to the project settings and go to the section **Webhooks** -4. Check the boxes **Push Events**, **Comments** and **Issues Events** -5. Paste the url and save - -Examples --------- - -### Close a Kanboard task when a commit pushed to Gitlab - -- Choose the event: **Gitlab commit received** -- Choose the action: **Close the task** - -When one or more commits are sent to Gitlab, Kanboard will receive the information, each commit message with a task number included will be closed. - -Example: - -- Commit message: "Fix bug #1234" -- That will close the Kanboard task #1234 - -### Create a Kanboard task when a new issue is opened on Gitlab - -- Choose the event: **Gitlab issue opened** -- Choose the action: **Create a task from an external provider** - -When a task is created from a Gitlab issue, the link to the issue is added to the description and the task have a new field named "Reference" (this is the Gitlab ticket number). - -### Close a Kanboard task when an issue is closed on Gitlab - -- Choose the event: **Gitlab issue closed** -- Choose the action: **Close the task** - -### Reopen a Kanboard task when a closed issue is reopened on Gitlab - -- Choose the event: **Gitlab issue reopened** -- Choose the action: **Open a task** - -### Create a comment on Kanboard when an issue is commented on Gitlab - -- Choose the event: **Gitlab issue comment created** -- Choose the action: **Create a comment from an external provider** - -If the username is the same between Gitlab and Kanboard the comment author will be assigned, otherwise there is no author. -The user also have to be member of the project in Kanboard. diff --git a/doc/index.markdown b/doc/index.markdown index bc3a2fbf..953dc72f 100644 --- a/doc/index.markdown +++ b/doc/index.markdown @@ -68,7 +68,6 @@ Using Kanboard ### Integrations -- [Gitlab webhooks](gitlab-webhooks.markdown) - [iCalendar subscriptions](ical.markdown) - [RSS/Atom subscriptions](rss.markdown) - [Json-RPC API](api-json-rpc.markdown) diff --git a/tests/units/Integration/GitlabWebhookTest.php b/tests/units/Integration/GitlabWebhookTest.php deleted file mode 100644 index afd9f7f1..00000000 --- a/tests/units/Integration/GitlabWebhookTest.php +++ /dev/null @@ -1,258 +0,0 @@ -container); - - $this->assertEquals(GitlabWebhook::TYPE_PUSH, $g->getType(json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_push.json'), true))); - $this->assertEquals(GitlabWebhook::TYPE_ISSUE, $g->getType(json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_issue_opened.json'), true))); - $this->assertEquals(GitlabWebhook::TYPE_COMMENT, $g->getType(json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_comment_created.json'), true))); - $this->assertEquals('', $g->getType(array())); - } - - public function testHandleCommit() - { - $g = new GitlabWebhook($this->container); - $p = new Project($this->container); - $tc = new TaskCreation($this->container); - $tf = new TaskFinder($this->container); - - $this->assertEquals(1, $p->create(array('name' => 'test'))); - $g->setProjectId(1); - - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_COMMIT, array($this, 'onCommit')); - - $event = json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_push.json'), true); - - // No task - $this->assertFalse($g->handleCommit($event['commits'][0])); - - // Create task with the wrong id - $this->assertEquals(1, $tc->create(array('title' => 'test1', 'project_id' => 1))); - $this->assertFalse($g->handleCommit($event['commits'][0])); - - // Create task with the right id - $this->assertEquals(2, $tc->create(array('title' => 'test2', 'project_id' => 1))); - $this->assertTrue($g->handleCommit($event['commits'][0])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertArrayHasKey(GitlabWebhook::EVENT_COMMIT.'.GitlabWebhookTest::onCommit', $called); - } - - public function testHandleIssueOpened() - { - $g = new GitlabWebhook($this->container); - $g->setProjectId(1); - - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_OPENED, array($this, 'onOpen')); - - $event = json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_issue_opened.json'), true); - $this->assertTrue($g->handleIssueOpened($event['object_attributes'])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertArrayHasKey(GitlabWebhook::EVENT_ISSUE_OPENED.'.GitlabWebhookTest::onOpen', $called); - } - - public function testHandleIssueReopened() - { - $g = new GitlabWebhook($this->container); - $p = new Project($this->container); - $tc = new TaskCreation($this->container); - $tf = new TaskFinder($this->container); - - $this->assertEquals(1, $p->create(array('name' => 'test'))); - $g->setProjectId(1); - - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_REOPENED, array($this, 'onReopen')); - - $event = json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_issue_reopened.json'), true); - - // Issue not there - $this->assertFalse($g->handleIssueReopened($event['object_attributes'])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertEmpty($called); - - $this->assertEquals(1, $tc->create(array('title' => 'A', 'project_id' => 1, 'reference' => 355691))); - $task = $tf->getByReference(1, 355691); - $this->assertTrue($g->handleIssueReopened($event['object_attributes'])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertArrayHasKey(GitlabWebhook::EVENT_ISSUE_REOPENED.'.GitlabWebhookTest::onReopen', $called); - } - - - public function testHandleIssueClosed() - { - $g = new GitlabWebhook($this->container); - $p = new Project($this->container); - $tc = new TaskCreation($this->container); - $tf = new TaskFinder($this->container); - - $this->assertEquals(1, $p->create(array('name' => 'test'))); - $g->setProjectId(1); - - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_CLOSED, array($this, 'onClose')); - - $event = json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_issue_closed.json'), true); - - // Issue not there - $this->assertFalse($g->handleIssueClosed($event['object_attributes'])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertEmpty($called); - - // Create a task with the issue reference - $this->assertEquals(1, $tc->create(array('title' => 'A', 'project_id' => 1, 'reference' => 355691))); - $task = $tf->getByReference(1, 355691); - $this->assertNotEmpty($task); - - $task = $tf->getByReference(2, 355691); - $this->assertEmpty($task); - - $this->assertTrue($g->handleIssueClosed($event['object_attributes'])); - - $called = $this->container['dispatcher']->getCalledListeners(); - $this->assertArrayHasKey(GitlabWebhook::EVENT_ISSUE_CLOSED.'.GitlabWebhookTest::onClose', $called); - } - - public function testCommentCreatedWithNoUser() - { - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithNoUser')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 355691, 'project_id' => 1))); - - $g = new GitlabWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_comment_created.json'), true) - )); - } - - public function testCommentCreatedWithNotMember() - { - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithNotMember')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 355691, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'minicoders'))); - - $g = new GitlabWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_comment_created.json'), true) - )); - } - - public function testCommentCreatedWithUser() - { - $this->container['dispatcher']->addListener(GitlabWebhook::EVENT_ISSUE_COMMENT, array($this, 'onCommentCreatedWithUser')); - - $p = new Project($this->container); - $this->assertEquals(1, $p->create(array('name' => 'foobar'))); - - $tc = new TaskCreation($this->container); - $this->assertEquals(1, $tc->create(array('title' => 'boo', 'reference' => 355691, 'project_id' => 1))); - - $u = new User($this->container); - $this->assertEquals(2, $u->create(array('username' => 'minicoders'))); - - $pp = new ProjectUserRole($this->container); - $this->assertTrue($pp->addUser(1, 2, Role::PROJECT_MEMBER)); - - $g = new GitlabWebhook($this->container); - $g->setProjectId(1); - - $this->assertNotFalse($g->parsePayload( - json_decode(file_get_contents(__DIR__.'/../fixtures/gitlab_comment_created.json'), true) - )); - } - - public function onOpen($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(355691, $data['reference']); - $this->assertEquals('Bug', $data['title']); - $this->assertEquals("There is a bug somewhere.\r\n\r\nBye\n\n[Gitlab Issue](https://gitlab.com/minicoders/test-webhook/issues/1)", $data['description']); - } - - public function onReopen($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(355691, $data['reference']); - } - public function onClose($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(355691, $data['reference']); - } - - public function onCommit($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(2, $data['task_id']); - $this->assertEquals('test2', $data['title']); - $this->assertEquals("Fix bug #2\n\n[Commit made by @Fred on Gitlab](https://gitlab.com/minicoders/test-webhook/commit/48aafa75eef9ad253aa254b0c82c987a52ebea78)", $data['comment']); - $this->assertEquals("Fix bug #2", $data['commit_message']); - $this->assertEquals('https://gitlab.com/minicoders/test-webhook/commit/48aafa75eef9ad253aa254b0c82c987a52ebea78', $data['commit_url']); - } - - public function onCommentCreatedWithNoUser($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(0, $data['user_id']); - $this->assertEquals(1642761, $data['reference']); - $this->assertEquals("Super comment!\n\n[By @minicoders on Gitlab](https://gitlab.com/minicoders/test-webhook/issues/1#note_1642761)", $data['comment']); - } - - public function onCommentCreatedWithNotMember($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(0, $data['user_id']); - $this->assertEquals(1642761, $data['reference']); - $this->assertEquals("Super comment!\n\n[By @minicoders on Gitlab](https://gitlab.com/minicoders/test-webhook/issues/1#note_1642761)", $data['comment']); - } - - public function onCommentCreatedWithUser($event) - { - $data = $event->getAll(); - $this->assertEquals(1, $data['project_id']); - $this->assertEquals(1, $data['task_id']); - $this->assertEquals(2, $data['user_id']); - $this->assertEquals(1642761, $data['reference']); - $this->assertEquals("Super comment!\n\n[By @minicoders on Gitlab](https://gitlab.com/minicoders/test-webhook/issues/1#note_1642761)", $data['comment']); - } -} diff --git a/tests/units/fixtures/gitlab_comment_created.json b/tests/units/fixtures/gitlab_comment_created.json deleted file mode 100644 index b6599419..00000000 --- a/tests/units/fixtures/gitlab_comment_created.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "object_kind": "note", - "user": { - "name": "Fred", - "username": "minicoders", - "avatar_url": "https://secure.gravatar.com/avatar/3c44936e5a56f80711bff14987d2733f?s=40&d=identicon" - }, - "project_id": 320820, - "repository": { - "name": "test-webhook", - "url": "git@gitlab.com:minicoders/test-webhook.git", - "description": "", - "homepage": "https://gitlab.com/minicoders/test-webhook" - }, - "object_attributes": { - "id": 1642761, - "note": "Super comment!", - "noteable_type": "Issue", - "author_id": 74067, - "created_at": "2015-07-17 21:37:48 UTC", - "updated_at": "2015-07-17 21:37:48 UTC", - "project_id": 320820, - "attachment": null, - "line_code": null, - "commit_id": "", - "noteable_id": 355691, - "st_diff": null, - "system": false, - "url": "https://gitlab.com/minicoders/test-webhook/issues/1#note_1642761" - }, - "issue": { - "id": 355691, - "title": "Bug", - "assignee_id": null, - "author_id": 74067, - "project_id": 320820, - "created_at": "2015-07-17 21:31:47 UTC", - "updated_at": "2015-07-17 21:37:48 UTC", - "position": 0, - "branch_name": null, - "description": "There is a bug somewhere.\r\n\r\nBye", - "milestone_id": null, - "state": "opened", - "iid": 1 - } -} \ No newline at end of file diff --git a/tests/units/fixtures/gitlab_issue_closed.json b/tests/units/fixtures/gitlab_issue_closed.json deleted file mode 100644 index 82500b3c..00000000 --- a/tests/units/fixtures/gitlab_issue_closed.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "object_kind": "issue", - "user": { - "name": "Fred", - "username": "minicoders", - "avatar_url": "https://secure.gravatar.com/avatar/3c44936e5a56f80711bff14987d2733f?s=40&d=identicon" - }, - "object_attributes": { - "id": 355691, - "title": "Bug", - "assignee_id": null, - "author_id": 74067, - "project_id": 320820, - "created_at": "2015-07-17 21:31:47 UTC", - "updated_at": "2015-07-17 22:10:17 UTC", - "position": 0, - "branch_name": null, - "description": "There is a bug somewhere.\r\n\r\nBye", - "milestone_id": null, - "state": "closed", - "iid": 1, - "url": "https://gitlab.com/minicoders/test-webhook/issues/1", - "action": "close" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/gitlab_issue_opened.json b/tests/units/fixtures/gitlab_issue_opened.json deleted file mode 100644 index 3e75c138..00000000 --- a/tests/units/fixtures/gitlab_issue_opened.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "object_kind": "issue", - "user": { - "name": "Fred", - "username": "minicoders", - "avatar_url": "https://secure.gravatar.com/avatar/3c44936e5a56f80711bff14987d2733f?s=40&d=identicon" - }, - "object_attributes": { - "id": 355691, - "title": "Bug", - "assignee_id": null, - "author_id": 74067, - "project_id": 320820, - "created_at": "2015-07-17 21:31:47 UTC", - "updated_at": "2015-07-17 21:31:47 UTC", - "position": 0, - "branch_name": null, - "description": "There is a bug somewhere.\r\n\r\nBye", - "milestone_id": null, - "state": "opened", - "iid": 1, - "url": "https://gitlab.com/minicoders/test-webhook/issues/1", - "action": "open" - } -} \ No newline at end of file diff --git a/tests/units/fixtures/gitlab_issue_reopened.json b/tests/units/fixtures/gitlab_issue_reopened.json deleted file mode 100644 index bf76262d..00000000 --- a/tests/units/fixtures/gitlab_issue_reopened.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "object_kind": "issue", - "user": { - "name": "Fred", - "username": "minicoders", - "avatar_url": "https://secure.gravatar.com/avatar/3c44936e5a56f80711bff14987d2733f?s=40&d=identicon" - }, - "object_attributes": { - "id": 355691, - "title": "Bug", - "assignee_id": null, - "author_id": 74067, - "project_id": 320820, - "created_at": "2015-07-17 21:31:47 UTC", - "updated_at": "2015-07-17 21:31:47 UTC", - "position": 0, - "branch_name": null, - "description": "There is a bug somewhere.\r\n\r\nBye", - "milestone_id": null, - "state": "opened", - "iid": 1, - "url": "https://gitlab.com/minicoders/test-webhook/issues/1", - "action": "reopen" - } -} diff --git a/tests/units/fixtures/gitlab_push.json b/tests/units/fixtures/gitlab_push.json deleted file mode 100644 index ed77f041..00000000 --- a/tests/units/fixtures/gitlab_push.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "object_kind": "push", - "before": "e4ec6156d208a45fc546fae73c28300b5af1692a", - "after": "48aafa75eef9ad253aa254b0c82c987a52ebea78", - "ref": "refs/heads/master", - "checkout_sha": "48aafa75eef9ad253aa254b0c82c987a52ebea78", - "message": null, - "user_id": 74067, - "user_name": "Fred", - "user_email": "f+gitlab@minicoders.com", - "project_id": 320820, - "repository": { - "name": "test-webhook", - "url": "git@gitlab.com:minicoders/test-webhook.git", - "description": "", - "homepage": "https://gitlab.com/minicoders/test-webhook", - "git_http_url": "https://gitlab.com/minicoders/test-webhook.git", - "git_ssh_url": "git@gitlab.com:minicoders/test-webhook.git", - "visibility_level": 0 - }, - "commits": [ - { - "id": "48aafa75eef9ad253aa254b0c82c987a52ebea78", - "message": "Fix bug #2", - "timestamp": "2015-06-21T00:41:41+00:00", - "url": "https://gitlab.com/minicoders/test-webhook/commit/48aafa75eef9ad253aa254b0c82c987a52ebea78", - "author": { - "name": "Fred", - "email": "me@localhost" - } - }, - { - "id": "e4ec6156d208a45fc546fae73c28300b5af1692a", - "message": "test", - "timestamp": "2015-06-21T00:35:55+00:00", - "url": "https://gitlab.com/localhost/test-webhook/commit/e4ec6156d208a45fc546fae73c28300b5af1692a", - "author": { - "name": "Fred", - "email": "me@localhost" - } - } - ], - "total_commits_count": 2 -} \ No newline at end of file -- cgit v1.2.3