8000 [Typo] Rename occurence to occurrence · symfony/symfony@11f746a · GitHub
[go: up one dir, main page]

Skip to content

Commit 11f746a

Browse files
committed
[Typo] Rename occurence to occurrence
1 parent e0de6cc commit 11f746a

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/DeprecationGroup.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ final class DeprecationGroup
3030
*/
3131
public function addNoticeFromObject($message, $class, $method)
3232
{
33-
$this->deprecationNotice($message)->addObjectOccurence($class, $method);
33+
$this->deprecationNotice($message)->addObjectOccurrence($class, $method);
3434
$this->addNotice();
3535
}
3636

@@ -39,7 +39,7 @@ public function addNoticeFromObject($message, $class, $method)
3939
*/
4040
public function addNoticeFromProceduralCode($message)
4141
{
42-
$this->deprecationNotice($message)->addProceduralOccurence();
42+
$this->deprecationNotice($message)->addProceduralOccurrence();
4343
$this->addNotice();
4444
}
4545

src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/DeprecationNotice.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ final class DeprecationNotice
2323
*/
2424
private $countsByCaller = [];
2525

26-
public function addObjectOccurence($class, $method)
26+
public function addObjectOccurrence($class, $method)
2727
{
2828
if (!isset($this->countsByCaller["$class::$method"])) {
2929
$this->countsByCaller["$class::$method"] = 0;
@@ -32,7 +32,7 @@ public function addObjectOccurence($class, $method)
3232
++$this->count;
3333
}
3434

35-
public function addProceduralOccurence()
35+
public function addProceduralOccurrence()
3636
{
3737
++$this->count;
3838
}

src/Symfony/Bridge/PhpUnit/Tests/DeprecationErrorHandler/DeprecationNoticeTest.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ final class DeprecationNoticeTest extends TestCase
1010
public function testItGroupsByCaller()
1111
{
1212
$notice = new DeprecationNotice();
13-
$notice->addObjectOccurence('MyAction', '__invoke');
14-
$notice->addObjectOccurence('MyAction', '__invoke');
15-
$notice->addObjectOccurence('MyOtherAction', '__invoke');
13+
$notice->addObjectOccurrence('MyAction', '__invoke');
14+
$notice->addObjectOccurrence('MyAction', '__invoke');
15+
$notice->addObjectOccurrence('MyOtherAction', '__invoke');
1616

1717
$countsByCaller = $notice->getCountsByCaller();
1818

@@ -23,13 +23,13 @@ public function testItGroupsByCaller()
2323
$this->assertSame(1, $countsByCaller['MyOtherAction::__invoke']);
2424
}
2525

26-
public function testItCountsBothTypesOfOccurences()
26+
public function testItCountsBothTypesOfOccurrences()
2727
{
2828
$notice = new DeprecationNotice();
29-
$notice->addObjectOccurence('MyAction', '__invoke');
29+
$notice->addObjectOccurrence('MyAction', '__invoke');
3030
$this->assertSame(1, $notice->count());
3131

32-
$notice->addProceduralOccurence();
32+
$notice->addProceduralOccurrence();
3333
$this->assertSame(2, $notice->count());
3434
}
3535
}

0 commit comments

Comments
 (0)
0