- Add source maps and license files for compiled assets - Add debug and test files for development - Complete Git repository with all necessary files for MoneyFlix project
29 lines
709 B
PHP
29 lines
709 B
PHP
<?php
|
|
require_once 'vendor/autoload.php';
|
|
|
|
use App\Core\Router;
|
|
|
|
$router = Router::getInstance();
|
|
require_once 'Routes/web.php';
|
|
|
|
echo "All routes loaded:\n";
|
|
$routes = $router->getRoutes();
|
|
foreach($routes as $method => $methodRoutes) {
|
|
echo "\n$method routes:\n";
|
|
foreach($methodRoutes as $path => $handler) {
|
|
if(strpos($path, '/api/') === 0) {
|
|
echo "- $path -> " . (is_array($handler) ? $handler[0] . '::' . $handler[1] : 'Closure') . "\n";
|
|
}
|
|
}
|
|
}
|
|
|
|
echo "\nTesting route match for /api/users/roles:\n";
|
|
$match = $router->match('GET', '/api/users/roles');
|
|
if($match) {
|
|
echo "Route found: " . print_r($match, true) . "\n";
|
|
} else {
|
|
echo "No route found\n";
|
|
}
|
|
|
|
|