aboutsummaryrefslogtreecommitdiff
path: root/test/unit/test_c_api.cpp
diff options
context:
space:
mode:
authorgithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2020-02-27 12:19:41 +0000
committerKristian Evers <kristianevers@gmail.com>2020-03-01 11:50:26 +0100
commit3c97d5b3a59f4ea26f5dfb98401b32d756480fb3 (patch)
tree885cda87d74b5d2669e816fc2d1bc4e25430b17b /test/unit/test_c_api.cpp
parentb86f349dab3b280eb28bb38143b5af036c3ff58f (diff)
downloadPROJ-3c97d5b3a59f4ea26f5dfb98401b32d756480fb3.tar.gz
PROJ-3c97d5b3a59f4ea26f5dfb98401b32d756480fb3.zip
Make tests independent of proj-datumgrid
Diffstat (limited to 'test/unit/test_c_api.cpp')
-rw-r--r--test/unit/test_c_api.cpp17
1 files changed, 3 insertions, 14 deletions
diff --git a/test/unit/test_c_api.cpp b/test/unit/test_c_api.cpp
index 12a48a65..0f1b906e 100644
--- a/test/unit/test_c_api.cpp
+++ b/test/unit/test_c_api.cpp
@@ -4144,10 +4144,7 @@ TEST_F(CApi, proj_create_crs_to_crs_with_only_ballpark_transformations) {
coord = proj_trans(Pnormalized, PJ_FWD, coord);
EXPECT_NEAR(coord.xyzt.x, 3.0, 1e-9);
EXPECT_NEAR(coord.xyzt.y, 40.65085651660555, 1e-9);
- if (coord.xyzt.z != 0) {
- // z will depend if the egm96_15.gtx grid is there or not
- EXPECT_NEAR(coord.xyzt.z, 47.04784081844435, 1e-3);
- }
+ EXPECT_NEAR(coord.xyzt.z, 47.72600023608570, 1e-3);
}
// ---------------------------------------------------------------------------
@@ -4156,10 +4153,6 @@ TEST_F(
CApi,
proj_create_crs_to_crs_from_custom_compound_crs_with_NAD83_2011_and_geoidgrid_ref_against_WGS84_to_WGS84_G1762) {
- if (strcmp(proj_grid_info("egm96_15.gtx").format, "missing") == 0) {
- return; // use GTEST_SKIP() if we upgrade gtest
- }
-
PJ *P;
PJ *inCrsH = proj_create_from_database(m_ctxt, "EPSG", "6340",
@@ -4214,7 +4207,7 @@ TEST_F(
EXPECT_NEAR(outcoord.xyzt.x, 35.09499307271, 1e-9);
EXPECT_NEAR(outcoord.xyzt.y, -118.64014868921, 1e-9);
- EXPECT_NEAR(outcoord.xyzt.z, 118.059, 1e-3);
+ EXPECT_NEAR(outcoord.xyzt.z, 117.655, 1e-3);
}
// ---------------------------------------------------------------------------
@@ -4223,10 +4216,6 @@ TEST_F(
CApi,
proj_create_crs_to_crs_from_custom_compound_crs_with_NAD83_2011_and_geoidgrid_ref_against_NAD83_2011_to_WGS84_G1762) {
- if (strcmp(proj_grid_info("egm96_15.gtx").format, "missing") == 0) {
- return; // use GTEST_SKIP() if we upgrade gtest
- }
-
PJ *P;
// NAD83(2011) 2D
@@ -4278,7 +4267,7 @@ TEST_F(
EXPECT_NEAR(outcoord.xyzt.x, 35.000003665064803, 1e-9);
EXPECT_NEAR(outcoord.xyzt.y, -118.00001414221214, 1e-9);
- EXPECT_NEAR(outcoord.xyzt.z, -32.5823, 1e-3);
+ EXPECT_NEAR(outcoord.xyzt.z, -32.8110, 1e-3);
}
// ---------------------------------------------------------------------------