-
-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added syncImageWithTiffProperties to the MagickReadSettings.
- Loading branch information
Showing
2 changed files
with
45 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
tests/settings/magick-read-settings/sync-image-with-tiff-profile.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* | ||
Copyright Dirk Lemstra https://github.com/dlemstra/magick-wasm. | ||
Licensed under the Apache License, Version 2.0. | ||
*/ | ||
|
||
import { MagickReadSettings } from '@src/settings/magick-read-settings'; | ||
|
||
describe('MagickReadSettings#syncImageWithTiffProperties', () => { | ||
it('should return true as the default value', () => { | ||
const settings = new MagickReadSettings(); | ||
|
||
expect(settings.syncImageWithTiffProperties).toBe(true); | ||
}); | ||
|
||
it('should not set the define when the value is not set', () => { | ||
const settings = new MagickReadSettings(); | ||
const value = settings.getDefine('tiff:sync-image'); | ||
|
||
expect(value).toBeNull(); | ||
}); | ||
|
||
it('should change the image option', () => { | ||
const settings = new MagickReadSettings(); | ||
settings.syncImageWithTiffProperties = false; | ||
|
||
const value = settings.getDefine('tiff:sync-image'); | ||
expect(value).toBe('false'); | ||
}); | ||
}); |