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 () => {
34
34
childProcess . kill ( ) ;
35
35
36
36
// 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' ) ;
50
42
} ) ;
51
43
} ) ;
You can’t perform that action at this time.
0 commit comments