refactor: move routes in dedicated files + improve routes management

This commit is contained in:
Sonny
2024-05-16 17:58:00 +02:00
committed by Sonny
parent 6b5aba6f84
commit 19b96650e9
14 changed files with 163 additions and 39 deletions

View File

@@ -3,6 +3,7 @@ import app from '@adonisjs/core/services/app';
import type { Config } from '@japa/runner/types';
import { pluginAdonisJS } from '@japa/plugin-adonisjs';
import testUtils from '@adonisjs/core/services/test_utils';
import { izzyRoutePlugin } from '@izzyjs/route/plugins/japa';
/**
* This file is imported by the "bin/test.ts" entrypoint file
@@ -12,7 +13,11 @@ import testUtils from '@adonisjs/core/services/test_utils';
* Configure Japa plugins in the plugins array.
* Learn more - https://japa.dev/docs/runner-config#plugins-optional
*/
export const plugins: Config['plugins'] = [assert(), pluginAdonisJS(app)];
export const plugins: Config['plugins'] = [
assert(),
pluginAdonisJS(app),
izzyRoutePlugin(),
];
/**
* Configure lifecycle function to run before and after all the