Passed
Pull Request — master (#47)
by
unknown
11:29
created

Suite   A

Complexity

Total Complexity 12

Size/Duplication

Total Lines 79
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 12
eloc 12
c 1
b 0
f 0
dl 0
loc 79
rs 10

12 Methods

Rating   Name   Duplication   Size   Complexity  
A stopOnFailure() 0 3 1
A getExcludePaths() 0 3 1
A getRunner() 0 3 1
A getIncludePaths() 0 3 1
A getInputLanguage() 0 3 1
A __construct() 0 13 1
A getSuiteName() 0 3 1
A isActive() 0 3 1
A getGlobalAttributes() 0 3 1
A readFromStdin() 0 3 1
A getFilter() 0 3 1
A getFileExtensions() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace hanneskod\readmetester\Config;
6
7
class Suite
8
{
9
    /**
10
     * @param array<string> $includePaths
11
     * @param array<string> $excludePaths
12
     * @param array<string> $fileExtensions
13
     * @param array<string> $globalAttributes
14
     */
15
    public function __construct(
16
        private string $name,
17
        private bool $active = true,
18
        private string $inputLanguage = '',
19
        private string $runner = '',
20
        private array $includePaths = [],
21
        private array $excludePaths = [],
22
        private array $fileExtensions = [],
23
        private array $globalAttributes = [],
24
        private bool $stopOnFailure = false,
25
        private string $filter = '',
26
        private bool $readFromStdin = false,
27
    ) {}
28
29
    public function getSuiteName(): string
30
    {
31
        return $this->name;
32
    }
33
34
    public function isActive(): bool
35
    {
36
        return $this->active;
37
    }
38
39
    public function getInputLanguage(): string
40
    {
41
        return $this->inputLanguage;
42
    }
43
44
    public function getRunner(): string
45
    {
46
        return $this->runner;
47
    }
48
49
    /** @return array<string> */
50
    public function getIncludePaths(): array
51
    {
52
        return $this->includePaths;
53
    }
54
55
    /** @return array<string> */
56
    public function getExcludePaths(): array
57
    {
58
        return $this->excludePaths;
59
    }
60
61
    /** @return array<string> */
62
    public function getFileExtensions(): array
63
    {
64
        return $this->fileExtensions;
65
    }
66
67
    public function readFromStdin(): bool
68
    {
69
        return $this->readFromStdin;
70
    }
71
72
    public function getFilter(): string
73
    {
74
        return $this->filter;
75
    }
76
77
    /** @return array<string> */
78
    public function getGlobalAttributes(): array
79
    {
80
        return $this->globalAttributes;
81
    }
82
83
    public function stopOnFailure(): bool
84
    {
85
        return $this->stopOnFailure;
86
    }
87
}
88