diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2019-02-20 10:36:14 +0100 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2019-02-20 10:36:14 +0100 |
| commit | f6232db745af1acd2473f51f82d006372c04fc55 (patch) | |
| tree | 12895f9453c4f6212b74634495493c1746a1f5b3 /test/unit/test_operation.cpp | |
| parent | 942722214e0b94bd848dac21c8e21923cf9f1c04 (diff) | |
| download | PROJ-f6232db745af1acd2473f51f82d006372c04fc55.tar.gz PROJ-f6232db745af1acd2473f51f82d006372c04fc55.zip | |
Add VERTCON grid name alternatives in database, and handle filename substitution for VERTCON method
Diffstat (limited to 'test/unit/test_operation.cpp')
| -rw-r--r-- | test/unit/test_operation.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/unit/test_operation.cpp b/test/unit/test_operation.cpp index 90deb661..58b740b6 100644 --- a/test/unit/test_operation.cpp +++ b/test/unit/test_operation.cpp @@ -6174,6 +6174,25 @@ TEST(operation, vertCRS_to_vertCRS) { // --------------------------------------------------------------------------- +TEST(operation, vertCRS_to_vertCRS_context) { + auto authFactory = + AuthorityFactory::create(DatabaseContext::create(), "EPSG"); + auto ctxt = CoordinateOperationContext::create(authFactory, nullptr, 0.0); + ctxt->setSpatialCriterion( + CoordinateOperationContext::SpatialCriterion::PARTIAL_INTERSECTION); + auto list = CoordinateOperationFactory::create()->createOperations( + // NGVD29 height (m) + authFactory->createCoordinateReferenceSystem("7968"), + // NAVD88 height (1) + authFactory->createCoordinateReferenceSystem("5703"), ctxt); + ASSERT_EQ(list.size(), 3U); + EXPECT_EQ(list[0]->nameStr(), "NGVD29 height (m) to NAVD88 height (3)"); + EXPECT_EQ(list[0]->exportToPROJString(PROJStringFormatter::create().get()), + "+proj=vgridshift +grids=vertcone.gtx +multiplier=0.001"); +} + +// --------------------------------------------------------------------------- + TEST(operation, compoundCRS_to_geogCRS_3D) { auto compoundcrs_ft_obj = PROJStringParser().createFromPROJString( |
