aboutsummaryrefslogtreecommitdiff
path: root/test/cli
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2020-12-02 17:12:54 +0100
committerEven Rouault <even.rouault@spatialys.com>2020-12-02 21:11:41 +0100
commit18ab7ef2e357e0c01464848a6911e754ebca471f (patch)
tree81aeb97f98f6e4be479e2ec2b9aed1678b2c326d /test/cli
parentebe00831b7d6de3aae01ddd5f3074e53ac6d981e (diff)
downloadPROJ-18ab7ef2e357e0c01464848a6911e754ebca471f.tar.gz
PROJ-18ab7ef2e357e0c01464848a6911e754ebca471f.zip
cs2cs / proj_create_crs_to_crs_from_pj(): add a --authority switch to control where coordinate operations are looked for (fixes #2442)
Diffstat (limited to 'test/cli')
-rwxr-xr-xtest/cli/testvarious13
-rw-r--r--test/cli/tv_out.dist7
2 files changed, 20 insertions, 0 deletions
diff --git a/test/cli/testvarious b/test/cli/testvarious
index 292ee316..82be4992 100755
--- a/test/cli/testvarious
+++ b/test/cli/testvarious
@@ -1009,6 +1009,19 @@ $EXE -f %.3f EPSG:4686 EPSG:6247 -E >> ${OUT} <<EOF
4.8 -74.25
EOF
+echo "##############################################################" >> ${OUT}
+echo "Test effect of --authority (https://github.com/OSGeo/PROJ/issues/2442)" >> ${OUT}
+echo "This test might be a bit fragile if proj.db content changes" >> ${OUT}
+echo "The first result should use the 'WGS_1984_(ITRF08)_To_NAD_1983_2011' (ESRI:108363) operation" >> ${OUT}
+echo "and the second one a no-op" >> ${OUT}
+$EXE -E +proj=latlong +datum=WGS84 +no_defs +to +init=epsg:6342 >> ${OUT} <<EOF
+-105 40
+EOF
+$EXE --authority EPSG -E +proj=latlong +datum=WGS84 +no_defs +to +init=epsg:6342 >> ${OUT} <<EOF
+-105 40
+EOF
+
+
# Done!
# do 'diff' with distribution results
echo "diff ${OUT} with ${OUT}.dist"
diff --git a/test/cli/tv_out.dist b/test/cli/tv_out.dist
index 70b2ab6e..fe1aa452 100644
--- a/test/cli/tv_out.dist
+++ b/test/cli/tv_out.dist
@@ -485,3 +485,10 @@ Test EPSG:xxxx EPSG:yyyy filename
##############################################################
Test Colombia Urban
4.8 -74.25 122543.174 80859.033 0.000
+##############################################################
+Test effect of --authority (https://github.com/OSGeo/PROJ/issues/2442)
+This test might be a bit fragile if proj.db content changes
+The first result should use the 'WGS_1984_(ITRF08)_To_NAD_1983_2011' (ESRI:108363) operation
+and the second one a no-op
+-105 40 500000.86 4427756.50 0.00
+-105 40 500000.00 4427757.22 0.00