Skip to content

Commit

Permalink
test: move HEIC tests to their own file
Browse files Browse the repository at this point in the history
  • Loading branch information
rprieto committed Apr 5, 2021
1 parent 35afdf2 commit a4596cf
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 40 deletions.
43 changes: 43 additions & 0 deletions test/integration/image-heic.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
const diff = require('./diff')

describe('image HEIC', () => {
it('can process a single-image HEIC file', done => {
diff.image({
input: 'images/heic-single.heic',
expect: 'images/heic-single.jpg',
options: {
height: 300
}
}, done)
})

it('can process a burst-image HEIC file', done => {
diff.image({
input: 'images/heic-burst.heic',
expect: 'images/heic-burst.jpg',
options: {
height: 300
}
}, done)
})

it('can process a live (photo + video) HEIC file', done => {
diff.image({
input: 'images/heic-live.heic',
expect: 'images/heic-live.jpg',
options: {
height: 300
}
}, done)
})

it('can process a HEIC with a P3 color profile', done => {
diff.image({
input: 'images/heic-color-profile.heic',
expect: 'images/heic-color-profile.jpg',
options: {
height: 300
}
}, done)
}, 10000)
})
40 changes: 0 additions & 40 deletions test/integration/image.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,46 +156,6 @@ describe('image', () => {
}, done)
})

it('can process a single-image HEIC file', done => {
diff.image({
input: 'images/heic-single.heic',
expect: 'images/heic-single.jpg',
options: {
height: 300
}
}, done)
})

it('can process a burst-image HEIC file', done => {
diff.image({
input: 'images/heic-burst.heic',
expect: 'images/heic-burst.jpg',
options: {
height: 300
}
}, done)
})

it('can process a live (photo + video) HEIC file', done => {
diff.image({
input: 'images/heic-live.heic',
expect: 'images/heic-live.jpg',
options: {
height: 300
}
}, done)
})

it('can process a HEIC with a P3 color profile', done => {
diff.image({
input: 'images/heic-color-profile.heic',
expect: 'images/heic-color-profile.jpg',
options: {
height: 300
}
}, done)
}, 10000)

const ORIENTATIONS = [1, 2, 3, 4, 5, 6, 7, 8]

ORIENTATIONS.forEach((orientation) => {
Expand Down

0 comments on commit a4596cf

Please sign in to comment.