File tree Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ async function redirectModule (moduleOptions) {
18
18
this . addServerMiddleware ( middleware )
19
19
}
20
20
21
- async function parseOptions ( options ) {
21
+ async function parseOptions ( options = { } ) {
22
22
if ( typeof options === 'function' ) {
23
23
options = await options ( )
24
24
}
Original file line number Diff line number Diff line change @@ -121,13 +121,17 @@ describe('function', () => {
121
121
} )
122
122
123
123
describe ( 'function inline' , ( ) => {
124
+ const inlineConfig = {
125
+ ...config ,
126
+ modules : [
127
+ [ require ( '../' ) , redirects ]
128
+ ]
129
+ }
130
+
131
+ delete inlineConfig . redirect
132
+
124
133
beforeAll ( async ( ) => {
125
- nuxt = await setupNuxt ( {
126
- ...config ,
127
- modules : [
128
- [ require ( '../' ) , redirects ]
129
- ]
130
- } )
134
+ nuxt = await setupNuxt ( inlineConfig )
131
135
} )
132
136
133
137
afterAll ( async ( ) => {
You can’t perform that action at this time.
0 commit comments