@@ -158,7 +158,7 @@ discard block |
||
158 | 158 | } |
159 | 159 | |
160 | 160 | /** |
161 | - * @param $section |
|
161 | + * @param string $section |
|
162 | 162 | * |
163 | 163 | * @return array |
164 | 164 | */ |
@@ -171,6 +171,9 @@ discard block |
||
171 | 171 | } |
172 | 172 | } |
173 | 173 | |
174 | + /** |
|
175 | + * @param string $name |
|
176 | + */ |
|
174 | 177 | public function getExtension($name) |
175 | 178 | { |
176 | 179 | if (array_key_exists($name, $this->extensions)) { |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | private function initConfigArray(array $configArray, array $defaultSettings = null) |
66 | 66 | { |
67 | 67 | if ($defaultSettings === null) { |
68 | - $defaultSettings = Yaml::parse(file_get_contents(__DIR__ . '/../settings/' . self::DEFAULT_SETTINGS)); |
|
68 | + $defaultSettings = Yaml::parse(file_get_contents(__DIR__.'/../settings/'.self::DEFAULT_SETTINGS)); |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | if (count($configArray) === 0) { |
@@ -167,7 +167,7 @@ discard block |
||
167 | 167 | if ($this->hasSection($section)) { |
168 | 168 | return $this->configArray[$section]; |
169 | 169 | } else { |
170 | - throw new \RuntimeException('The section (' . $section . ') you are trying to access does not exist.'); |
|
170 | + throw new \RuntimeException('The section ('.$section.') you are trying to access does not exist.'); |
|
171 | 171 | } |
172 | 172 | } |
173 | 173 | |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | if (array_key_exists($name, $this->extensions)) { |
177 | 177 | return $this->extensions[$name]; |
178 | 178 | } else { |
179 | - throw new \RuntimeException('The extension ("' . $name . '") you are trying to access does not exist. Registered extensions are: ' . implode(' ,', array_keys($this->extensions)) . '.'); |
|
179 | + throw new \RuntimeException('The extension ("'.$name.'") you are trying to access does not exist. Registered extensions are: '.implode(' ,', array_keys($this->extensions)).'.'); |
|
180 | 180 | } |
181 | 181 | } |
182 | 182 | |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | try { |
202 | 202 | $client = Init::initialize($this->configArray['client']); |
203 | 203 | } catch (\Exception $e) { |
204 | - throw new ConfigurationException('Error initializing client (' . $e->getMessage() . ')'); |
|
204 | + throw new ConfigurationException('Error initializing client ('.$e->getMessage().')'); |
|
205 | 205 | } |
206 | 206 | |
207 | 207 | if (array_key_exists('cache', $this->configArray['client'])) { |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | * Result constructor. |
27 | 27 | * |
28 | 28 | * @param $status |
29 | - * @param $value |
|
29 | + * @param integer $value |
|
30 | 30 | * @param $message |
31 | 31 | */ |
32 | 32 | public function __construct($status, $message = '', $value = null) |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | } |
46 | 46 | |
47 | 47 | /** |
48 | - * @param array $attributes |
|
48 | + * @param array $attribute |
|
49 | 49 | */ |
50 | 50 | public function addAttribute(Attribute $attribute) |
51 | 51 | { |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
72 | - * @return mixed |
|
72 | + * @return string |
|
73 | 73 | */ |
74 | 74 | public function getMessage() |
75 | 75 | { |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | } |
86 | 86 | |
87 | 87 | /** |
88 | - * @param Response $response |
|
88 | + * @param ResponseInterface $response |
|
89 | 89 | */ |
90 | 90 | public function setResponse(ResponseInterface $response) |
91 | 91 | { |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | 6 | use whm\Html\Document; |
7 | -use whm\Smoke\Http\Response; |
|
8 | 7 | |
9 | 8 | /** |
10 | 9 | * This rules counts the css files that are included in a document. If the number is higher |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | 6 | use whm\Html\Document; |
7 | -use whm\Smoke\Http\Response; |
|
8 | 7 | |
9 | 8 | /** |
10 | 9 | * This rules counts the js files that are included in a document. If the number is higher |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | 6 | use Symfony\Component\DomCrawler\Crawler; |
7 | -use whm\Smoke\Http\Response; |
|
8 | 7 | use whm\Smoke\Rules\StandardRule; |
9 | 8 | |
10 | 9 | /** |
@@ -3,7 +3,6 @@ |
||
3 | 3 | namespace whm\Smoke\Rules\Http; |
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | -use whm\Smoke\Http\Response; |
|
7 | 6 | use whm\Smoke\Rules\Rule; |
8 | 7 | |
9 | 8 | abstract class HttpsRule implements Rule |
@@ -3,7 +3,6 @@ |
||
3 | 3 | namespace whm\Smoke\Rules\Image; |
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | -use whm\Smoke\Http\Response; |
|
7 | 6 | use whm\Smoke\Rules\StandardRule; |
8 | 7 | |
9 | 8 | /** |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use JsonSchema\Validator; |
6 | 6 | use Psr\Http\Message\ResponseInterface; |
7 | -use whm\Smoke\Http\Response; |
|
8 | 7 | use whm\Smoke\Rules\StandardRule; |
9 | 8 | use whm\Smoke\Rules\ValidationFailedException; |
10 | 9 |
@@ -4,8 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Psr\Http\Message\ResponseInterface; |
6 | 6 | use Symfony\Component\DomCrawler\Crawler; |
7 | -use whm\Smoke\Http\Response; |
|
8 | -use whm\Smoke\Rules\Rule; |
|
9 | 7 | use whm\Smoke\Rules\StandardRule; |
10 | 8 | |
11 | 9 | /** |