add test for new macro behavior

This commit is contained in:
Tom Witkowski
2020-06-21 14:02:56 +02:00
parent ef5715ce10
commit 53a8c7b05e
2 changed files with 17 additions and 2 deletions

12
tests/Features/Macro.php Normal file
View File

@ -0,0 +1,12 @@
<?php
use Illuminate\Support\Traits\Macroable;
use PHPUnit\Framework\TestCase;
uses(Macroable::class);
it('can call chained macro method')->macro('bar', function () {
assertInstanceOf(TestCase::class, $this);
return $this;
})->bar();