Passed
Branch master (3fb2a1)
by Andrés
02:45
created

AbstractSymfonyTask::getOptions()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 6
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 10
ccs 7
cts 7
cp 1
crap 1
rs 10
1
<?php
2
3
/*
4
 * This file is part of the Magallanes package.
5
 *
6
 * (c) Andrés Montañez <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Mage\Task\BuiltIn\Symfony;
13
14
use Mage\Task\AbstractTask;
15
16
/**
17
 * Abstract Symfony Task
18
 *
19
 * @author Andrés Montañez <[email protected]>
20
 */
21
abstract class AbstractSymfonyTask extends AbstractTask
22
{
23
    /**
24
     * @return array<string, string>
25
     */
26 20
    protected function getOptions(): array
27
    {
28 20
        $options = array_merge(
29 20
            ['console' => 'bin/console', 'env' => 'dev', 'flags' => ''],
30 20
            $this->getSymfonyOptions(),
31 20
            $this->runtime->getMergedOption('symfony'),
32 20
            $this->options
33
        );
34
35 20
        return $options;
36
    }
37
38
    /**
39
     * @return array<string, string|null>
40
     */
41 19
    protected function getSymfonyOptions(): array
42
    {
43 19
        return [];
44
    }
45
}
46