aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHoward Butler <howard@hobu.co>2015-03-04 17:22:38 +0000
committerHoward Butler <howard@hobu.co>2015-03-04 17:22:38 +0000
commit3f6d7af47470deac6ff156e569ec3e7a91ebbf3b (patch)
treec10b2db58c2896c0c41f9d645219ce9aec07676f
parented9bcafef638ea449235a3e307b943e8a8fe1557 (diff)
downloadPROJ-3f6d7af47470deac6ff156e569ec3e7a91ebbf3b.tar.gz
PROJ-3f6d7af47470deac6ff156e569ec3e7a91ebbf3b.zip
move flakey tests into their own script so they aren't run with 'make check' by default #255
git-svn-id: http://svn.osgeo.org/metacrs/proj/trunk@2646 4e78687f-474d-0410-85f9-8d5e500ac6b2
-rwxr-xr-xnad/testflakey74
-rwxr-xr-xnad/testvarious21
-rw-r--r--nad/tf_out.dist13
-rw-r--r--nad/tv_out.dist13
4 files changed, 87 insertions, 34 deletions
diff --git a/nad/testflakey b/nad/testflakey
new file mode 100755
index 00000000..2d57d395
--- /dev/null
+++ b/nad/testflakey
@@ -0,0 +1,74 @@
+:
+# Script to do some testing of flakey transformation that do not depend
+# on datum files.
+#
+#
+NAD_DIR=`dirname $0`
+EXE=$1
+
+usage()
+{
+ echo "Usage: ${0} <path to 'cs2cs' program>"
+ echo
+ exit 1
+}
+
+if test -z "${EXE}"; then
+ EXE=../src/cs2cs
+fi
+
+if test ! -x ${EXE}; then
+ echo "*** ERROR: Can not find '${EXE}' program!"
+ exit 1
+fi
+
+echo "============================================"
+echo "Running ${0} using ${EXE}:"
+echo "============================================"
+
+OUT=tf_out
+#EXE=../src/cs2cs
+#
+echo "doing tests into file ${OUT}, please wait"
+rm -f ${OUT}
+#
+echo "Test healpix inverse projection on sphere" >> ${OUT}
+$EXE +proj=latlong +a=1 +lon_0=0 \
+ +to +proj=healpix +a=1 +lon_0=0 -f '%.'5'f' -I\
+ -E >>${OUT} <<EOF
+0 0.7853981633974483
+-1.5707963267948966 0
+EOF
+$EXE +proj=latlong +a=5 \
+ +to +proj=healpix +a=5 -f '%.'5'f' -I\
+ -E >>${OUT} <<EOF
+0.0 0.0
+0.0 3.9269908169872414
+0.0 -3.9269908169872414
+7.853981633974483 0.0
+-7.853981633974483 0.0
+-15.707963267948966 0.0
+-11.780972450961723 7.853981633974483
+-11.780972450961723 -7.853981633974483
+1.437378399445537 5.364369216432778
+1.437378399445537 -5.364369216432778
+EOF
+
+##############################################################################
+# Done!
+# do 'diff' with distribution results
+echo "diff ${OUT} with ${OUT}.dist"
+diff -b ${OUT} ${NAD_DIR}/${OUT}.dist
+if [ $? -ne 0 ] ; then
+ echo ""
+ echo "PROBLEMS HAVE OCCURED"
+ echo "test file ${OUT} saved"
+ echo
+ exit 100
+else
+ echo "TEST OK"
+ echo "test file ${OUT} removed"
+ echo
+ /bin/rm -f ${OUT}
+ exit 0
+fi
diff --git a/nad/testvarious b/nad/testvarious
index c2f99009..a128eb50 100755
--- a/nad/testvarious
+++ b/nad/testvarious
@@ -277,27 +277,6 @@ $EXE +proj=latlong +R=5 \
0 60.0
0 -60.0
EOF
-echo "Test healpix inverse projection on sphere" >> ${OUT}
-$EXE +proj=latlong +a=1 +lon_0=0 \
- +to +proj=healpix +a=1 +lon_0=0 -f '%.'5'f' -I\
- -E >>${OUT} <<EOF
-0 0.7853981633974483
--1.5707963267948966 0
-EOF
-$EXE +proj=latlong +a=5 \
- +to +proj=healpix +a=5 -f '%.'5'f' -I\
- -E >>${OUT} <<EOF
-0.0 0.0
-0.0 3.9269908169872414
-0.0 -3.9269908169872414
-7.853981633974483 0.0
--7.853981633974483 0.0
--15.707963267948966 0.0
--11.780972450961723 7.853981633974483
--11.780972450961723 -7.853981633974483
-1.437378399445537 5.364369216432778
-1.437378399445537 -5.364369216432778
-EOF
echo "Test healpix forward projection on ellipsoid" >> ${OUT}
$EXE +proj=latlong +a=1 +lon_0=0 +ellps=WGS84 \
+to +proj=healpix +a=1 +lon_0=0 +ellps=WGS84 -f '%.'5'f' \
diff --git a/nad/tf_out.dist b/nad/tf_out.dist
new file mode 100644
index 00000000..9f1778e7
--- /dev/null
+++ b/nad/tf_out.dist
@@ -0,0 +1,13 @@
+Test healpix inverse projection on sphere
+0 0.7853981633974483 0.00000 41.81031 0.00000
+-1.5707963267948966 0 -90.00000 0.00000 0.00000
+0.0 0.0 0.00000 0.00000 0.00000
+0.0 3.9269908169872414 0.00000 41.81031 0.00000
+0.0 -3.9269908169872414 0.00000 -41.81031 0.00000
+7.853981633974483 0.0 90.00000 0.00000 0.00000
+-7.853981633974483 0.0 -90.00000 0.00000 0.00000
+-15.707963267948966 0.0 -180.00000 0.00000 0.00000
+-11.780972450961723 7.853981633974483 -180.00000 90.00000 0.00000
+-11.780972450961723 -7.853981633974483 -180.00000 -90.00000 0.00000
+1.437378399445537 5.364369216432778 0.00000 60.00000 0.00000
+1.437378399445537 -5.364369216432778 0.00000 -60.00000 0.00000
diff --git a/nad/tv_out.dist b/nad/tv_out.dist
index 5ee7fe5a..d36ab5b2 100644
--- a/nad/tv_out.dist
+++ b/nad/tv_out.dist
@@ -105,19 +105,6 @@ Test healpix forward projection on sphere
-180 -90.0 -19.63495 -7.85398 0.00000
0 60.0 1.43738 5.36437 0.00000
0 -60.0 1.43738 -5.36437 0.00000
-Test healpix inverse projection on sphere
-0 0.7853981633974483 0.00000 41.81031 0.00000
--1.5707963267948966 0 -90.00000 0.00000 0.00000
-0.0 0.0 0.00000 0.00000 0.00000
-0.0 3.9269908169872414 0.00000 41.81031 0.00000
-0.0 -3.9269908169872414 0.00000 -41.81031 0.00000
-7.853981633974483 0.0 90.00000 0.00000 0.00000
--7.853981633974483 0.0 -90.00000 0.00000 0.00000
--15.707963267948966 0.0 -180.00000 0.00000 0.00000
--11.780972450961723 7.853981633974483 -180.00000 90.00000 0.00000
--11.780972450961723 -7.853981633974483 -180.00000 -90.00000 0.00000
-1.437378399445537 5.364369216432778 -0.00000 60.00000 0.00000
-1.437378399445537 -5.364369216432778 -0.00000 -60.00000 0.00000
Test healpix forward projection on ellipsoid
0 41.937853904844985 0.00000 0.78452 0.00000
-90 0 -1.56904 0.00000 0.00000