• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lmc-eu / matej-client-php / 7529439147

15 Jan 2024 01:18PM UTC coverage: 100.0%. Remained the same
7529439147

Pull #145

github

web-flow
Bump actions/checkout from 3 to 4

Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Pull Request #145: Bump actions/checkout from 3 to 4

712 of 712 relevant lines covered (100.0%)

35.03 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

100.0
/src/Exception/AuthorizationException.php
1
<?php declare(strict_types=1);
2

3
namespace Lmc\Matej\Exception;
4

5
use Psr\Http\Message\RequestInterface;
6
use Psr\Http\Message\ResponseInterface;
7

8
/**
9
 * Exception thrown when request authorization fails.
10
 */
11
class AuthorizationException extends RequestException
12
{
13
    public static function fromRequestAndResponse(
14
        RequestInterface $request,
15
        ResponseInterface $response,
16
        \Throwable $previous = null
17
    ): self {
18
        $responseData = json_decode($response->getBody()->getContents());
14✔
19

20
        $message = sprintf(
14✔
21
            'Matej API authorization error for url "%s"%s',
14✔
22
            $request->getRequestTarget(),
14✔
23
            isset($responseData->message) ? ' (' . $responseData->message . ')' : ''
14✔
24
        );
14✔
25

26
        return new self($message, $request, $response, $previous);
14✔
27
    }
28
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc