Passed
Push — master ( 9875bc...1abeda )
by John
04:45
created

AuthnetInvalidAmountException::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 3
crap 1
1
<?php
0 ignored issues
show
Coding Style introduced by
Class found in ".php" file; use ".inc" extension instead
Loading history...
Coding Style introduced by
The PHP open tag does not have a corresponding PHP close tag
Loading history...
Coding Style introduced by
Filename "AuthnetInvalidAmountException.php" doesn't match the expected filename "authnetinvalidamountexception.php"
Loading history...
2
3
declare(strict_types=1);
4
5
/**
0 ignored issues
show
Coding Style introduced by
Block comments must be started with /*
Loading history...
6
 * This file is part of the AuthnetJSON package.
7
 *
8
 * (c) John Conde <[email protected]>
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace JohnConde\Authnet;
15
16
use Throwable;
17
18
/**
19
 * Exception that is thrown when invalid amount to pay is provided for a SIM transaction
20
 *
21
 * @author     John Conde <[email protected]>
0 ignored issues
show
Coding Style introduced by
Tag value for @author tag indented incorrectly; expected 4 spaces but found 5
Loading history...
22
 * @copyright  John Conde <[email protected]>
0 ignored issues
show
Coding Style introduced by
Tag value for @copyright tag indented incorrectly; expected 1 spaces but found 2
Loading history...
23
 * @license    http://www.apache.org/licenses/LICENSE-2.0.html Apache License, Version 2.0
0 ignored issues
show
Coding Style introduced by
Tag value for @license tag indented incorrectly; expected 3 spaces but found 4
Loading history...
24
 * @link       https://github.com/stymiee/authnetjson
0 ignored issues
show
Coding Style introduced by
Tag value for @link tag indented incorrectly; expected 6 spaces but found 7
Loading history...
25
 */
26
class AuthnetInvalidAmountException extends AuthnetException
27
{
0 ignored issues
show
Coding Style introduced by
Opening brace should be on the same line as the declaration for class AuthnetInvalidAmountException
Loading history...
28 1
    public function __construct(string $message = '', int $code = 0, Throwable $previous = null)
0 ignored issues
show
Coding Style introduced by
Expected 2 blank lines before function; 0 found
Loading history...
introduced by
Missing doc comment for function __construct()
Loading history...
Coding Style introduced by
Incorrect spacing between argument "$message" and equals sign; expected 0 but found 1
Loading history...
Coding Style introduced by
Incorrect spacing between default value and equals sign for argument "$message"; expected 0 but found 1
Loading history...
Coding Style introduced by
Incorrect spacing between argument "$code" and equals sign; expected 0 but found 1
Loading history...
Coding Style introduced by
Incorrect spacing between default value and equals sign for argument "$code"; expected 0 but found 1
Loading history...
Coding Style introduced by
Incorrect spacing between argument "$previous" and equals sign; expected 0 but found 1
Loading history...
Coding Style introduced by
Incorrect spacing between default value and equals sign for argument "$previous"; expected 0 but found 1
Loading history...
Coding Style introduced by
TRUE, FALSE and NULL should be uppercase as per the configured coding-style; instead of null please use NULL.
Loading history...
29
    {
0 ignored issues
show
Coding Style introduced by
Opening brace should be on the same line as the declaration
Loading history...
30 1
        parent::__construct($message, $code, $previous);
31 1
    }
0 ignored issues
show
Coding Style introduced by
Expected 2 blank lines after function; 0 found
Loading history...
Coding Style introduced by
Expected 1 blank line before closing function brace; 0 found
Loading history...
Coding Style introduced by
Expected //end __construct()
Loading history...
32
}
0 ignored issues
show
Coding Style introduced by
Expected //end class
Loading history...
Coding Style introduced by
As per coding style, files should not end with a newline character.

This check marks files that end in a newline character, i.e. an empy line.

Loading history...
33