Skip to content

Commit ff18658

Browse files
committed
fixed file pathes in the test
1 parent 1737089 commit ff18658

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/serve-static.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ describe('Serve Static Middleware', () => {
6969
expect(res.text).toBe('<h1>Hello Hono</h1>')
7070
expect(res.headers['content-type']).toBe('text/html; charset=utf-8')
7171
expect(res.headers['x-custom']).toMatch(
72-
/Found the file at .*\/test\/assets\/static\/index\.html$/
72+
/Found the file at .*[\/\\]test[\/\\]assets[\/\\]static[\/\\]index\.html$/
7373
)
7474
})
7575

@@ -170,7 +170,7 @@ describe('Serve Static Middleware', () => {
170170
const res = await request(server).get('/on-not-found/foo.txt')
171171
expect(res.status).toBe(404)
172172
expect(notFoundMessage).toMatch(
173-
/.*\/not-found\/on-not-found\/foo\.txt is not found, request to \/on-not-found\/foo\.txt$/
173+
/.*[\/\\]not-found[\/\\]on-not-found[\/\\]foo\.txt is not found, request to \/on-not-found\/foo\.txt$/
174174
)
175175
})
176176

0 commit comments

Comments
 (0)