GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Branch dev (d5e133)
by Андрей
20:27 queued 13s
created

TestController   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 46
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 2
Bugs 0 Features 0
Metric Value
wmc 3
lcom 0
cbo 3
dl 0
loc 46
rs 10
c 2
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A prepareWorkflowDataHandler() 0 6 1
A testCondition() 0 4 1
A testAction() 0 11 1
1
<?php
2
/**
3
 * @link    https://github.com/old-town/workflow-zf2-dispatch
4
 * @author  Malofeykin Andrey  <[email protected]>
5
 */
6
namespace OldTown\Workflow\ZF2\Dispatch\PhpUnit\TestData\IntegrationTest;
7
8
use Zend\Mvc\Controller\AbstractActionController;
9
use Zend\View\Model\ViewModel;
10
use OldTown\Workflow\ZF2\Dispatch\Annotation as WFD;
11
use OldTown\Workflow\ZF2\Dispatch\Dispatcher\Dispatcher;
12
13
14
/**
15
 * Class TestController
16
 *
17
 * @package OldTown\Workflow\ZF2\Dispatch\PhpUnit\TestData\IntegrationTest
18
 */
19
class TestController extends AbstractActionController
20
{
21
22
    /**
23
     * Подготовка данных для workflow
24
     *
25
     * @return array
26
     */
27
    public function prepareWorkflowDataHandler()
28
    {
29
        return [
30
            'test' => 'testData'
31
        ];
32
    }
33
34
    /**
35
     * Условие для запуска workflow
36
     */
37
    public function testCondition()
38
    {
39
        return true;
40
    }
41
42
43
    /**
44
     * @WFD\WorkflowDispatch(enabled=true, activity="initialize")
45
     * @WFD\PrepareData(type="method", handler="prepareWorkflowDataHandler", enabled=true)
46
     * @WFD\DispatchConditions(
47
     *     conditions={
48
     *         @WFD\Condition(type="method", handler="testCondition"),
49
     *         @WFD\Condition(type="service", handler="httpMethod", params={"allowedHttpMethods":{"GET"}})
50
     *     }
51
     * )
52
     */
53
    public function testAction()
54
    {
55
        $this->getEvent()->getParam(Dispatcher::WORKFLOW_DISPATCH_EVENT);
56
57
58
59
        $viewModel = new ViewModel();
60
        $viewModel->setTerminal(true);
61
62
        return $viewModel;
63
    }
64
}
65