for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types = 1);
namespace PurpleBooth\GitGithubLint\Validator;
use PurpleBooth\GitGithubLint\Message;
use PurpleBooth\GitGithubLint\Status\SeperateSubjectFromBodyWithABlankLineStatus;
use PurpleBooth\GitGithubLint\Status\Status;
use PurpleBooth\GitGithubLint\Status\SuccessStatus;
/**
* This validator will check the subject and the body have a blank line in between te two
*
* @see SeperateSubjectFromBodyWithABlankLineStatus
* @see SuccessStatus
* @package PurpleBooth\GitGithubLint\Validator
*/
class SeperateSubjectFromBodyWithABlankLineValidator implements Validator
{
* Check if a message passes a specific test, and return a status that identifies if it is or isn't
* @param Message $message
* @return Status
public function validate(Message $message) : Status
if (!$message->hasBlankLineAfterTitle()) {
return new SeperateSubjectFromBodyWithABlankLineStatus();
}
return new SuccessStatus();