Skip to content

Commit

Permalink
Merge pull request #3724 from rouault/fix_test_gdalwarp_lib_135
Browse files Browse the repository at this point in the history
Fix unreleased regression related to 78d563c, that caused GDAL's test_gdalwarp_lib_135 test to fail
  • Loading branch information
rouault authored May 11, 2023
2 parents 03fac0e + e1b006e commit cfed44d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/iso19111/operation/singleoperation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,9 @@ bool CoordinateOperation::isPROJInstantiable(
}
for (const auto &gridDesc :
gridsNeeded(databaseContext, considerKnownGridsAsAvailable)) {
if (!gridDesc.available) {
// Grid name starting with @ are considered as optional.
if (!gridDesc.available &&
(gridDesc.shortName.empty() || gridDesc.shortName[0] != '@')) {
return false;
}
}
Expand Down
7 changes: 7 additions & 0 deletions test/cli/testvarious
Original file line number Diff line number Diff line change
Expand Up @@ -1247,6 +1247,13 @@ echo 39 -3 0 | PROJ_DISPLAY_PROGRAM_NAME=NO PROJ_DATA=tmp_dir PROJ_DEBUG=2 $EXE

rm -rf tmp_dir

echo "##############################################################" >> ${OUT}
echo "Test cs2cs grid missing with @gridname" >> ${OUT}

$EXE +proj=longlat +datum=WGS84 +units=m +geoidgrids=@i_dont_exist.tif +vunits=m +no_defs +type=crs +to EPSG:4979 >> ${OUT} <<EOF
2 49 0
EOF

echo "##############################################################" >> ${OUT}
echo "Test Similarity Transformation (example from EPSG Guidance Note 7.2)" >> ${OUT}
#
Expand Down
3 changes: 3 additions & 0 deletions test/cli/tv_out.dist
Original file line number Diff line number Diff line change
Expand Up @@ -607,6 +607,9 @@ cannot initialize transformation
cause: File not found or invalid
program abnormally terminated
##############################################################
Test cs2cs grid missing with @gridname
49dN 2dE 0.000
##############################################################
Test Similarity Transformation (example from EPSG Guidance Note 7.2)
300000 4500000 299905.060 4499796.515 0.000
##############################################################
Expand Down

0 comments on commit cfed44d

Please sign in to comment.