Skip to content

Commit

Permalink
Also read the created image.
Browse files Browse the repository at this point in the history
  • Loading branch information
dlemstra committed Sep 22, 2023
1 parent 2c9ca89 commit e004261
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/coders/heic.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Copyright Dirk Lemstra https://github.com/dlemstra/magick-wasm.
// Licensed under the Apache License, Version 2.0.

import { ImageMagick } from '../../src/image-magick';
import { MagickFormat } from '../../src/magick-format';
import { TestImages } from '../test-images';

Expand All @@ -9,6 +10,9 @@ describe('Coders#heic', () => {
TestImages.Builtin.logo.use((image) => {
image.write(MagickFormat.Avif, data => {
expect(data.length).toBe(11386);
ImageMagick.read(data, image => {
expect(image.format).toBe(MagickFormat.Avif);
});
});
});
});
Expand Down

0 comments on commit e004261

Please sign in to comment.