diff --git a/packages/gatsby-plugin-sharp/src/__tests__/images/wide-aspect-ratio.png b/packages/gatsby-plugin-sharp/src/__tests__/images/wide-aspect-ratio.png new file mode 100644 index 0000000000000..c63a28149ffab Binary files /dev/null and b/packages/gatsby-plugin-sharp/src/__tests__/images/wide-aspect-ratio.png differ diff --git a/packages/gatsby-plugin-sharp/src/__tests__/index.js b/packages/gatsby-plugin-sharp/src/__tests__/index.js index 7f8400615b81d..437e60fab3ee5 100644 --- a/packages/gatsby-plugin-sharp/src/__tests__/index.js +++ b/packages/gatsby-plugin-sharp/src/__tests__/index.js @@ -549,6 +549,18 @@ describe(`gatsby-plugin-sharp`, () => { } `) }) + + it(`handles really wide aspect ratios for blurred placeholder`, async () => { + const result = await base64({ + file: getFileObject( + path.join(__dirname, `images/wide-aspect-ratio.png`) + ), + args, + }) + + expect(result.width).toEqual(20) + expect(result.height).toEqual(1) + }) }) describe(`tracedSVG`, () => {