Skip to content

Commit

Permalink
Test PDF driver
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Aug 13, 2024
1 parent 0a1028d commit 41f6713
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
6 changes: 6 additions & 0 deletions recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -181,11 +181,17 @@ outputs:
- libgdal-core >={{ ".".join(version.split(".")[:2]) }}
- poppler
test:
files:
- test_data
- test_pdf.bat
- test_pdf.sh
commands:
- test -f ${PREFIX}/lib/gdalplugins/${GDAL_PLUGIN_TYPE}_${GDAL_PLUGIN_NAME}${SHLIB_EXT} # [unix]
- if not exist %LIBRARY_LIB%\gdalplugins\%GDAL_PLUGIN_TYPE%_%GDAL_PLUGIN_NAME%.dll exit 1 # [win]
- gdalinfo --format ${GDAL_PLUGIN_NAME} # [unix]
- gdalinfo --format %GDAL_PLUGIN_NAME% # [win]
- test_pdf.sh # [unix]
- test_pdf.bat # [win]
about:
summary: Raster driver PDF for the Geospatial Data Abstraction Library (GDAL)
license: MIT
Expand Down
Binary file added recipe/test_data/test_iso32000.pdf
Binary file not shown.
4 changes: 4 additions & 0 deletions recipe/test_pdf.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
cd %~dp0\test_data

gdalinfo test_iso32000.pdf
if errorlevel 1 exit 1
12 changes: 12 additions & 0 deletions recipe/test_pdf.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash

# exit when any command fails
set -e
# print all commands
set -x

pushd $( dirname "${BASH_SOURCE[0]}" )/test_data/

gdalinfo test_iso32000.pdf

popd

0 comments on commit 41f6713

Please sign in to comment.