Skip to content

Commit

Permalink
Fix more typos (#625)
Browse files Browse the repository at this point in the history
* Fix more typos

* Fix StrTest

* fix the fix
  • Loading branch information
szepeviktor authored Jan 17, 2025
1 parent c216e9f commit 7a6609d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions bin/docblock.php
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ function resolveDocParamType( $method, $parameter ) {
$paramTypeNode = collect( parseDocblock( $method->getDocComment() )->getParamTagValues() )
->firstWhere( 'parameterName', '$' . $parameter->getName() );

// As we didn't find a param type, we will now recursivly check if the prototype has a value specified...
// As we didn't find a param type, we will now recursively check if the prototype has a value specified...

if ( $paramTypeNode === null ) {
try {
Expand Down Expand Up @@ -523,7 +523,7 @@ function resolveDocTags( $docblock, $tag ) {
}

/**
* Recursivly resolve docblock mixins.
* Recursively resolve docblock mixins.
*
* @param \ReflectionClass $class
* @return \Illuminate\Support\Collection<\ReflectionClass>
Expand Down
8 changes: 4 additions & 4 deletions tests/Support/StrTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ public function testStrExcerpt() {
$this->assertSame( 'This is a...', Str::excerpt( 'This is a beautiful morning', 'this', [ 'radius' => 5 ] ) );
$this->assertSame( '...iful morning', Str::excerpt( 'This is a beautiful morning', 'morning', [ 'radius' => 5 ] ) );
$this->assertNull( Str::excerpt( 'This is a beautiful morning', 'day' ) );
$this->assertSame( '...is a beautiful! mor...', Str::excerpt( 'This is a beautiful! morning', 'Beautiful', [ 'radius' => 5 ] ) );
$this->assertSame( '...is a beautiful? mor...', Str::excerpt( 'This is a beautiful? morning', 'beautiful', [ 'radius' => 5 ] ) );
$this->assertSame( '...is a beautiful! morn...', Str::excerpt( 'This is a beautiful! morning', 'Beautiful', [ 'radius' => 6 ] ) );
$this->assertSame( '...is a beautiful? morn...', Str::excerpt( 'This is a beautiful? morning', 'beautiful', [ 'radius' => 6 ] ) );
$this->assertSame( '', Str::excerpt( '', '', [ 'radius' => 0 ] ) );
$this->assertSame( 'a', Str::excerpt( 'a', 'a', [ 'radius' => 0 ] ) );
$this->assertSame( '...b...', Str::excerpt( 'abc', 'B', [ 'radius' => 0 ] ) );
Expand All @@ -173,9 +173,9 @@ public function testStrExcerpt() {
)
);
$this->assertSame(
'This is the ultimate supercalifragilisticexpialidoceous very looooooooooooooooooong looooooooooooong beautiful morning with amazing sunshine and awesome tempera[...]',
'This is the ultimate supercalifragilisticexpialidocious very looooooooooooooooooong looooooooooooong beautiful morning with amazing sunshine and awesome tempera[...]',
Str::excerpt(
'This is the ultimate supercalifragilisticexpialidoceous very looooooooooooooooooong looooooooooooong beautiful morning with amazing sunshine and awesome temperatures. So what are you gonna do about it?',
'This is the ultimate supercalifragilisticexpialidocious very looooooooooooooooooong looooooooooooong beautiful morning with amazing sunshine and awesome temperatures. So what are you gonna do about it?',
'very',
[ 'omission' => '[...]' ],
)
Expand Down

0 comments on commit 7a6609d

Please sign in to comment.