Passed
Pull Request — master (#3)
by
unknown
02:08 queued 20s
created

action_plugin_description_test   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A testHeaders() 0 9 1
1
<?php
2
3
/**
4
 * Action tests for the description plugin.
5
 *
6
 * @group plugin_description
7
 * @group plugins
8
 *
9
 * @author Mark C. Prins <[email protected]>
10
 *
11
 * @noinspection AutoloadingIssuesInspection
12
 * @phpcs:disable Squiz.Classes.ValidClassName.NotCamelCaps
13
 */
14
class action_plugin_description_test extends DokuWikiTest
1 ignored issue
show
Bug introduced by
The type DokuWikiTest was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
15
{
16
    protected $pluginsEnabled = array('description');
17
18
    /**
19
     * @throws Exception if anything goes wrong
20
     */
21
    final public function testHeaders(): void
22
    {
23
        $request = new TestRequest();
1 ignored issue
show
Bug introduced by
The type TestRequest was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
24
        $response = $request->get(array('id' => 'wiki:syntax'));
25
26
        // check description meta headers
27
        $this->assertStringContainsString(
28
            'DokuWiki supports some simple markup language',
29
            $response->queryHTML('meta[name="description"]')->attr('content')
30
        );
31
    }
32
}
33