From deef4312c9f92e95e410645316172aeebbc0f68f Mon Sep 17 00:00:00 2001 From: Daniel Roe Date: Tue, 6 Jun 2023 21:42:53 +0100 Subject: [PATCH] test: revert bundle update --- test/unit/bundle.spec.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/unit/bundle.spec.ts b/test/unit/bundle.spec.ts index 9b0021be..6286b1b4 100644 --- a/test/unit/bundle.spec.ts +++ b/test/unit/bundle.spec.ts @@ -78,7 +78,7 @@ describe('project sizes', () => { const modules = await analyzeSizes('node_modules/**/*', serverDir) expect(roundToKilobytes(modules.totalBytes)).toMatchInlineSnapshot( - '"32201k"' + '"32465k"' ) const packages = modules.files @@ -265,7 +265,7 @@ describe('project sizes', () => { }) }) -async function analyzeSizes (pattern: string | string[], rootDir: string) { +async function analyzeSizes(pattern: string | string[], rootDir: string) { const files: string[] = await globby(pattern, { cwd: rootDir }) let totalBytes = 0 for (const file of files) { @@ -282,6 +282,6 @@ async function analyzeSizes (pattern: string | string[], rootDir: string) { return { files, totalBytes } } -function roundToKilobytes (bytes: number) { +function roundToKilobytes(bytes: number) { return (bytes / 1024).toFixed(bytes > 100 * 1024 ? 0 : 1) + 'k' } -- knotmirror 0.0.1