Nwidart\Modules\Support\Migrations\NameParser::is PHP Méthode

is() public méthode

Determine whether the given type is same with the current schema action or type.
public is ( $type ) : boolean
$type
Résultat boolean
    public function is($type)
    {
        return $type === $this->getAction();
    }

Usage Example

 /** @test */
 public function it_can_check_if_current_migration_type_matches_given_type()
 {
     $parser = new NameParser('create_users_table');
     self::assertTrue($parser->is('create'));
 }