01: /*
02: * GeoTools - OpenSource mapping toolkit
03: * http://geotools.org
04: * (C) 2004-2006, Geotools Project Managment Committee (PMC)
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation; either
09: * version 2.1 of the License, or (at your option) any later version.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: */
16: package org.geotools.data.wfs;
17:
18: import java.io.IOException;
19: import java.net.MalformedURLException;
20: import java.net.URL;
21: import java.util.NoSuchElementException;
22:
23: import junit.framework.TestCase;
24:
25: import org.geotools.feature.IllegalAttributeException;
26: import org.xml.sax.SAXException;
27:
28: /**
29: * summary sentence.
30: * <p>
31: * Paragraph ...
32: * </p><p>
33: * Responsibilities:
34: * <ul>
35: * <li>
36: * <li>
37: * </ul>
38: * </p><p>
39: * Example:<pre><code>
40: * GeoServer x = new GeoServer( ... );
41: * TODO code example
42: * </code></pre>
43: * </p>
44: * @author dzwiers
45: * @since 0.6.0
46: * @source $URL: http://svn.geotools.org/geotools/tags/2.4.1/modules/plugin/wfs/src/test/java/org/geotools/data/wfs/CubewerksOnlineTest.java $
47: */
48: public class CubewerksOnlineTest extends TestCase {
49:
50: private URL url = null;
51:
52: public CubewerksOnlineTest() throws MalformedURLException {
53:
54: //old server -- do not test version 0.0.16
55: // url = new URL("http://ceoware2.ccrs.nrcan.gc.ca/cubewerx/cwwfs/cubeserv.cgi?datastore=CEOWARE2&version=1.0.0&service=WFS&request=GetCapabilities");
56: // url = new URL("http://cgns.nrcan.gc.ca/wfs/cubeserv.cgi?DATASTORE=cgns&REQUEST=GetCapabilities&VERSION=1.0.0&SERVICE=WFS");
57: url = new URL(
58: "http://demo.cubewerx.com/demo/cubeserv/cubeserv.cgi?SERVICE=wfs&DATASTORE=Foundation&version=1.0.0");
59: }
60:
61: public void testFeatureType() throws NoSuchElementException,
62: IOException, SAXException {
63: WFSDataStoreReadTest.doFeatureType(url, true, true, 6);
64: }
65:
66: public void testFeatureReader() throws NoSuchElementException,
67: IOException, IllegalAttributeException, SAXException {
68: WFSDataStoreReadTest.doFeatureReader(url, true, true, 6);
69: }
70:
71: public void testFeatureReaderWithFilter()
72: throws NoSuchElementException, IllegalAttributeException,
73: IOException, SAXException {
74: WFSDataStoreReadTest.doFeatureReaderWithQuery(url, true, true,
75: 6);
76: }
77: }
|