Error: The action test.json is not defined in EventsController
AppController.php
$this->loadComponent('RequestHandler');
routes.php
Router::extensions(['json','pdf','xlsx','jpg','csv','ldif','ics']);
EventsController.php
public function test(){
$this->Authorization->skipAuthorization();
$users = $this->Events->Users->find();
$this->set(compact(‘users’));
$this->viewBuilder()->setOption(‘serialize’, [‘users’]);
}
What am I missing?