diff --git a/tests/EventsAuthorizationTest.php b/tests/EventsAuthorizationTest.php index 30060f3..ae383fd 100644 --- a/tests/EventsAuthorizationTest.php +++ b/tests/EventsAuthorizationTest.php @@ -18,7 +18,8 @@ public function testEventIsAuthorized1() HeyMan::whenEventHappens(['myEvent', 'myEvent1'])->youShouldHaveRole('reader')->otherwise()->weDenyAccess(); app(StartGuarding::class)->start(); - MakeSure::about($this)->whenEventHappens('myEvent1')->exceptionIsThrown(AuthorizationException::class); + $this->expectException(AuthorizationException::class); + event('myEvent1'); } public function testEventIsAuthorized2()