Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

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
Pull Request — dev-extbase-fluid (#756)
by
unknown
03:39
created

PageViewProxyDisabledTest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 11
c 1
b 0
f 0
dl 0
loc 27
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A queryProxy() 0 6 1
A canAccessPageWithUrlHash() 0 11 1
1
<?php
2
3
namespace Kitodo\Dlf\Tests\Functional\Api;
4
5
use Kitodo\Dlf\Tests\Functional\FunctionalTestCase;
6
use TYPO3\CMS\Core\Utility\GeneralUtility;
7
8
class PageViewProxyDisabledTest extends FunctionalTestCase
9
{
10
    protected $disableJsonWrappedResponse = true;
11
12
    protected function queryProxy(array $query, string $method = 'GET')
13
    {
14
        $query['eID'] = 'tx_dlf_pageview_proxy';
15
16
        return $this->httpClient->request($method, $this->baseUrl, [
17
            'query' => $query,
18
        ]);
19
    }
20
21
    /**
22
     * @test
23
     */
24
    public function canAccessPageWithUrlHash(): void
25
    {
26
        $targetUrl = 'http://web:8001/Tests/Fixtures/PageViewProxy/test.txt';
27
        $uHash = GeneralUtility::hmac($targetUrl, 'PageViewProxy');
28
29
        $response = $this->queryProxy([
30
            'url' => $targetUrl,
31
            'uHash' => $uHash,
32
        ]);
33
34
        $this->assertEquals(404, $response->getStatusCode());
35
    }
36
}
37