mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-26 23:52:06 +00:00
test: update font preload to use regex
This commit is contained in:
parent
ab039f051a
commit
7c7f1e7d9c
@ -42,8 +42,8 @@ describe('with-config', () => {
|
||||
|
||||
test('/ (preload fonts)', async () => {
|
||||
const { html } = await nuxt.server.renderRoute('/')
|
||||
expect(html).toContain(
|
||||
'<link rel="preload" href="/test/orion/fonts/roboto.dd02ea4.woff2" as="font" type="font/woff2" crossorigin'
|
||||
expect(html).toMatch(
|
||||
/<link rel="preload" href="\/test\/orion\/fonts\/roboto.[\w]{7}.woff2" as="font" type="font\/woff2" crossorigin/
|
||||
)
|
||||
})
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user