Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This getter allows to create tests for the route
middlewares, which is currently not possible because the property is protected. For example, if you want to ensure that a route middleware has been registered, with this getter you can write: ```php /** @test */ public function it_registers_a_custom_route_middleware() { $middlewares = resolve(\App\Http\Kernel::class)->getMiddlewareGroups(); $this->assertArrayHasKey('custom', $middlewares); $this->assertEquals(\App\Http\Middleware\Custom::class, $middlewares['custom']); } ```
- Loading branch information