mirror of
https://github.com/sveltejs/svelte.git
synced 2024-11-25 17:19:22 +01:00
normalize paths in comments in cli tests
This commit is contained in:
parent
bd1884a953
commit
860a117f0e
@ -9,7 +9,10 @@ const cli = path.resolve(__dirname, "../../cli/index.ts.js");
|
||||
function normalize(str) {
|
||||
return str
|
||||
.replace(/^\s+$/gm, '')
|
||||
.replace(/generated by Svelte v[.\d]+/, `generated by Svelte vx.y.z`)
|
||||
.replace(
|
||||
/\/\*(.*?)generated by Svelte v[.\d]+/,
|
||||
(_, path) => `/*${path.replace(/\\/g, '/')}generated by Svelte vx.y.z`
|
||||
)
|
||||
.trim();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user