-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #554 from lesserwhirls/g3
Support godiva3 configuration
- Loading branch information
Showing
7 changed files
with
89 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
tds/src/integrationTests/java/thredds/server/wms/TestGodiva3.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/* | ||
* Copyright (c) 1998-2024 University Corporation for Atmospheric Research/Unidata | ||
* See LICENSE.txt for license information. | ||
*/ | ||
|
||
package thredds.server.wms; | ||
|
||
import static com.google.common.truth.Truth.assertThat; | ||
|
||
import jakarta.servlet.http.HttpServletResponse; | ||
import java.nio.charset.StandardCharsets; | ||
import org.junit.Test; | ||
import thredds.test.util.TestOnLocalServer; | ||
|
||
|
||
public class TestGodiva3 { | ||
|
||
@Test | ||
public void testGodiva3GetConfig() { | ||
String endpoint = TestOnLocalServer.withHttpPath("/getconfig"); | ||
byte[] result = | ||
TestOnLocalServer.getContent(endpoint, HttpServletResponse.SC_OK, "application/json;charset=iso-8859-1"); | ||
String jsonStr = new String(result, StandardCharsets.ISO_8859_1); | ||
assertThat(jsonStr).isEqualTo("{\"mapWidth\":1024,\"mapHeight\":512}"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
mapHeight=512 | ||
mapWidth=1024 | ||
#proxy=http://proxyUrlGoesHere/ | ||
# Definition of user layers | ||
# First we define a layer with ID "user" | ||
# The URL of the WMS. MANDATORY | ||
#userURL=http://wmsurl.com/with/query/separator/wms? | ||
# The Title for the layer switcher. Defaults to the ID (i.e. "user" in this case) | ||
#userTitle=My WMS Layer | ||
# The layer(s) to plot. MANDATORY | ||
#userLayers=wmslayer1,wmslayer2 | ||
# The projection to use. Defaults to "CRS:84" | ||
#userProjection=EPSG:4326 | ||
# The WMS version to use. Defaults to "1.1.1" | ||
#userVersion=1.3.0 | ||
# The image format to use. Defaults to "image/png" | ||
#userFormat=image/png | ||
# Whether a layer should be switched on at load. Can be defined for multiple overlays, but only for one base layer | ||
#userOnByDefault=true | ||
# Whether to use as an overlay (as opposed to a base map). Defaults to false | ||
#userIsOverlay=true |