mirror of
https://github.com/nestjs/nest.git
synced 2026-02-21 23:11:44 +00:00
test: fix testing problem
This commit is contained in:
@@ -23,7 +23,11 @@ describe('ApplicationConfig', () => {
|
||||
it('should set global path options', () => {
|
||||
const options: GlobalPrefixOptions<ExcludeRouteMetadata> = {
|
||||
exclude: [
|
||||
{ pathRegex: new RegExp(/health/), requestMethod: RequestMethod.GET },
|
||||
{
|
||||
pathRegex: new RegExp(/health/),
|
||||
requestMethod: RequestMethod.GET,
|
||||
path: 'health',
|
||||
},
|
||||
],
|
||||
};
|
||||
appConfig.setGlobalPrefixOptions(options);
|
||||
|
||||
@@ -249,6 +249,7 @@ describe('RoutePathFactory', () => {
|
||||
{
|
||||
pathRegex: pathToRegexp('/random'),
|
||||
requestMethod: RequestMethod.ALL,
|
||||
path: '/random',
|
||||
},
|
||||
],
|
||||
});
|
||||
@@ -267,6 +268,7 @@ describe('RoutePathFactory', () => {
|
||||
{
|
||||
pathRegex: pathToRegexp('/cats'),
|
||||
requestMethod: RequestMethod.ALL,
|
||||
path: '/cats',
|
||||
},
|
||||
],
|
||||
});
|
||||
@@ -285,6 +287,7 @@ describe('RoutePathFactory', () => {
|
||||
{
|
||||
pathRegex: pathToRegexp('/cats'),
|
||||
requestMethod: RequestMethod.GET,
|
||||
path: '/cats',
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user