diff --git a/packages/publications/src/Actions/ValidatesPublicationSchema.php b/packages/publications/src/Actions/PublicationSchemaValidator.php similarity index 95% rename from packages/publications/src/Actions/ValidatesPublicationSchema.php rename to packages/publications/src/Actions/PublicationSchemaValidator.php index bfaa6393bce..cb8dfa83740 100644 --- a/packages/publications/src/Actions/ValidatesPublicationSchema.php +++ b/packages/publications/src/Actions/PublicationSchemaValidator.php @@ -12,9 +12,9 @@ use function validator; /** - * @see \Hyde\Publications\Testing\Feature\ValidatesPublicationSchemaTest + * @see \Hyde\Publications\Testing\Feature\PublicationSchemaValidatorTest */ -class ValidatesPublicationSchema extends InvokableAction +class PublicationSchemaValidator extends InvokableAction { protected stdClass $schema; protected Validator $schemaValidator; diff --git a/packages/publications/src/Commands/ValidatePublicationTypesCommand.php b/packages/publications/src/Commands/ValidatePublicationTypesCommand.php index 11cd2873e02..4baa5059e12 100644 --- a/packages/publications/src/Commands/ValidatePublicationTypesCommand.php +++ b/packages/publications/src/Commands/ValidatePublicationTypesCommand.php @@ -9,7 +9,7 @@ use function dirname; use function glob; use Hyde\Hyde; -use Hyde\Publications\Actions\ValidatesPublicationSchema; +use Hyde\Publications\Actions\PublicationSchemaValidator; use Hyde\Publications\PublicationService; use InvalidArgumentException; use function json_encode; @@ -74,7 +74,7 @@ protected function validateSchemaFiles(): void foreach ($schemaFiles as $schemaFile) { $publicationName = basename(dirname($schemaFile)); - $this->results[$publicationName] = ValidatesPublicationSchema::call($publicationName, false)->errors(); + $this->results[$publicationName] = PublicationSchemaValidator::call($publicationName, false)->errors(); } } diff --git a/packages/publications/src/Models/PublicationType.php b/packages/publications/src/Models/PublicationType.php index c969fd56613..a803882f7ab 100644 --- a/packages/publications/src/Models/PublicationType.php +++ b/packages/publications/src/Models/PublicationType.php @@ -13,7 +13,7 @@ use Hyde\Framework\Concerns\InteractsWithDirectories; use Hyde\Framework\Features\Paginator; use Hyde\Hyde; -use Hyde\Publications\Actions\ValidatesPublicationSchema; +use Hyde\Publications\Actions\PublicationSchemaValidator; use Hyde\Publications\PublicationService; use Hyde\Support\Concerns\Serializable; use Hyde\Support\Contracts\SerializableContract; @@ -228,6 +228,6 @@ public function validateSchemaFile(bool $throw = true): ?array { $method = $throw ? 'validate' : 'errors'; - return ValidatesPublicationSchema::call($this->getIdentifier(), $throw)->$method(); + return PublicationSchemaValidator::call($this->getIdentifier(), $throw)->$method(); } } diff --git a/packages/publications/tests/Feature/ValidatesPublicationSchemaTest.php b/packages/publications/tests/Feature/PublicationSchemaValidatorTest.php similarity index 97% rename from packages/publications/tests/Feature/ValidatesPublicationSchemaTest.php rename to packages/publications/tests/Feature/PublicationSchemaValidatorTest.php index f7b40691613..24b41852baa 100644 --- a/packages/publications/tests/Feature/ValidatesPublicationSchemaTest.php +++ b/packages/publications/tests/Feature/PublicationSchemaValidatorTest.php @@ -9,9 +9,9 @@ use Illuminate\Validation\ValidationException; /** - * @covers \Hyde\Publications\Actions\ValidatesPublicationSchema + * @covers \Hyde\Publications\Actions\PublicationSchemaValidator */ -class ValidatesPublicationSchemaTest extends TestCase +class PublicationSchemaValidatorTest extends TestCase { public function testValidateSchemaFile() {