File tree Expand file tree Collapse file tree 1 file changed +5
-13
lines changed Expand file tree Collapse file tree 1 file changed +5
-13
lines changed Original file line number Diff line number Diff line change @@ -34,18 +34,10 @@ describe('server config', async () => {
3434 childProcess . kill ( ) ;
3535
3636 // Check if the server config is merged correctly
37- const rsbuildConfig = await import ( rsbuildConfigFile ) ;
38- expect ( rsbuildConfig . default . server ) . toMatchInlineSnapshot ( `
39- {
40- "base": "/",
41- "compress": true,
42- "host": "0.0.0.0",
43- "htmlFallback": "index",
44- "open": true,
45- "port": 3002,
46- "printUrls": false,
47- "strictPort": false,
48- }
49- ` ) ;
37+ const rsbuildConfigContent = await fse . readFile ( rsbuildConfigFile , 'utf-8' ) ;
38+ expect ( rsbuildConfigContent ) . toContain ( `base: '/'` ) ;
39+ expect ( rsbuildConfigContent ) . toContain ( 'open: true' ) ;
40+ expect ( rsbuildConfigContent ) . toContain ( 'port: 3002' ) ;
41+ expect ( rsbuildConfigContent ) . toContain ( 'printUrls: false' ) ;
5042 } ) ;
5143} ) ;
You can’t perform that action at this time.
0 commit comments