Skip to content

Commit

Permalink
update test recipe to check result
Browse files Browse the repository at this point in the history
  • Loading branch information
jgstew committed Aug 16, 2023
1 parent b079c83 commit 3d799be
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
2 changes: 2 additions & 0 deletions SharedProcessors/FileGetMagicType.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
# brew install libmagic
# Ubuntu:
# apt-get install libmagic-dev
# python module:
# python3 -m pip install --upgrade python-magic
import magic
from autopkglib import ( # pylint: disable=import-error,unused-import
Processor,
Expand Down
9 changes: 9 additions & 0 deletions Test-Recipes/FileImageSvgToPng.test.recipe.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,12 @@ Process:
- Processor: com.github.jgstew.SharedProcessors/FileImageSvgToPng
Arguments:
max_pixel_dim: 200

- Processor: com.github.jgstew.SharedProcessors/FileGetMagicType
Arguments:
file_pathname: "%file_path_png%"

- Processor: com.github.jgstew.SharedProcessors/AssertInputContainsString
Arguments:
input_string: "%file_mime_type%"
assert_string: "image/png"

0 comments on commit 3d799be

Please sign in to comment.