aboutsummaryrefslogtreecommitdiff
path: root/test/unit
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-07-08 13:22:01 +0200
committerGitHub <noreply@github.com>2021-07-08 13:22:01 +0200
commitfe9be0e766d18d129e6926bb13dd864970df5df2 (patch)
tree76b7dafcf628afbf4c2feedb9d69e482aec60f40 /test/unit
parent9a46b4ac490c415bc8a98d8bfcfd241b1490e0fe (diff)
parent209d742c2f194e439b0e3da7293c32360dd26848 (diff)
downloadPROJ-fe9be0e766d18d129e6926bb13dd864970df5df2.tar.gz
PROJ-fe9be0e766d18d129e6926bb13dd864970df5df2.zip
Merge pull request #2769 from rouault/fix_2768
createOperations(): make sure to associate an extent to the transform…
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/test_c_api.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/test/unit/test_c_api.cpp b/test/unit/test_c_api.cpp
index 90641bd1..34f32c19 100644
--- a/test/unit/test_c_api.cpp
+++ b/test/unit/test_c_api.cpp
@@ -5082,7 +5082,20 @@ TEST_F(CApi, proj_create_vertical_crs_ex_implied_accuracy) {
ObjectKeeper keeper_transform(transform);
// This is the accuracy of operations EPSG:5656 / 5657
- ASSERT_EQ(proj_coordoperation_get_accuracy(m_ctxt, transform), 0.15);
+ const double acc = proj_coordoperation_get_accuracy(m_ctxt, transform);
+ EXPECT_NEAR(acc, 0.15, 1e-10);
+
+ // Check there's an asssociated area of use
+ double west_lon_degree = 0;
+ double south_lat_degree = 0;
+ double east_lon_degree = 0;
+ double north_lat_degree = 0;
+ ASSERT_EQ(proj_get_area_of_use(m_ctxt, transform, &west_lon_degree,
+ &south_lat_degree, &east_lon_degree,
+ &north_lat_degree, nullptr),
+ true);
+ EXPECT_LE(north_lat_degree, -10);
+ EXPECT_GE(west_lon_degree, 110);
}
// ---------------------------------------------------------------------------