Skip to content

Commit

Permalink
Rename classes and interfaces [24]
Browse files Browse the repository at this point in the history
  • Loading branch information
jrfnl committed Dec 22, 2023
1 parent 8cee7bd commit a57657b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"Yoast\\WHIP\\Config\\Composer\\Actions::check_coding_standards"
],
"check-cs-thresholds": [
"@putenv YOASTCS_THRESHOLD_ERRORS=9",
"@putenv YOASTCS_THRESHOLD_ERRORS=10",
"@putenv YOASTCS_THRESHOLD_WARNINGS=0",
"Yoast\\WHIP\\Config\\Composer\\Actions::check_cs_thresholds"
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
/**
* Exception for an invalid version comparison string.
*/
class Whip_InvalidVersionComparisonString extends Exception {
class InvalidVersionComparisonString extends Exception {

/**
* InvalidVersionComparisonString constructor.
Expand Down
6 changes: 3 additions & 3 deletions src/VersionRequirement.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
use Yoast\WHIPv2\Exceptions\EmptyProperty;
use Yoast\WHIPv2\Exceptions\InvalidOperatorType;
use Yoast\WHIPv2\Exceptions\InvalidType;
use Yoast\WHIPv2\Exceptions\Whip_InvalidVersionComparisonString;
use Yoast\WHIPv2\Exceptions\InvalidVersionComparisonString;
use Yoast\WHIPv2\Interfaces\Requirement;

/**
Expand Down Expand Up @@ -84,7 +84,7 @@ public function operator() {
*
* @return VersionRequirement The parsed version requirement.
*
* @throws Whip_InvalidVersionComparisonString When an invalid version comparison string is passed.
* @throws InvalidVersionComparisonString When an invalid version comparison string is passed.
*/
public static function fromCompareString( $component, $comparisonString ) {

Expand All @@ -98,7 +98,7 @@ public static function fromCompareString( $component, $comparisonString ) {
`x';

if ( ! \preg_match( $matcher, $comparisonString, $match ) ) {
throw new Whip_InvalidVersionComparisonString( $comparisonString );
throw new InvalidVersionComparisonString( $comparisonString );
}

$version = $match[2];
Expand Down
2 changes: 1 addition & 1 deletion tests/Unit/VersionRequirementTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public static function dataFromCompareString() {
*/
public function testFromCompareStringException() {
$this->expectExceptionHelper(
'\Yoast\WHIPv2\Exceptions\Whip_InvalidVersionComparisonString',
'\Yoast\WHIPv2\Exceptions\InvalidVersionComparisonString',
'Invalid version comparison string. Example of a valid version comparison string: >=5.3. Passed version comparison string: > 2.3'
);

Expand Down

0 comments on commit a57657b

Please sign in to comment.