Tests: tighten composite offset thresholds

This commit is contained in:
Lovell Fuller 2020-02-15 10:53:30 +00:00
parent e44c12f029
commit 1717173f17
5 changed files with 4 additions and 4 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

@ -141,7 +141,7 @@ describe('composite', () => {
it('zero offset', done => { it('zero offset', done => {
sharp(fixtures.inputJpg) sharp(fixtures.inputJpg)
.resize(400) .resize(80)
.composite([{ .composite([{
input: fixtures.inputPngWithTransparency16bit, input: fixtures.inputPngWithTransparency16bit,
top: 0, top: 0,
@ -157,7 +157,7 @@ describe('composite', () => {
it('offset and gravity', done => { it('offset and gravity', done => {
sharp(fixtures.inputJpg) sharp(fixtures.inputJpg)
.resize(400) .resize(80)
.composite([{ .composite([{
input: fixtures.inputPngWithTransparency16bit, input: fixtures.inputPngWithTransparency16bit,
left: 10, left: 10,
@ -174,7 +174,7 @@ describe('composite', () => {
it('offset, gravity and tile', done => { it('offset, gravity and tile', done => {
sharp(fixtures.inputJpg) sharp(fixtures.inputJpg)
.resize(400) .resize(80)
.composite([{ .composite([{
input: fixtures.inputPngWithTransparency16bit, input: fixtures.inputPngWithTransparency16bit,
left: 10, left: 10,
@ -192,7 +192,7 @@ describe('composite', () => {
it('offset and tile', done => { it('offset and tile', done => {
sharp(fixtures.inputJpg) sharp(fixtures.inputJpg)
.resize(400) .resize(80)
.composite([{ .composite([{
input: fixtures.inputPngWithTransparency16bit, input: fixtures.inputPngWithTransparency16bit,
left: 10, left: 10,