/*
 *    GeoTools - OpenSource mapping toolkit
 *    http://geotools.org
 *    (C) 2004-2006, Geotools Project Managment Committee (PMC)
 *
 *    This library is free software; you can redistribute it and/or
 *    modify it under the terms of the GNU Lesser General Public
 *    License as published by the Free Software Foundation; either
 *    version 2.1 of the License, or (at your option) any later version.
 *
 *    This library is distributed in the hope that it will be useful,
 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *    Lesser General Public License for more details.
 */
package org.geotools.data.wms.test;

import java.io.InputStream;
import java.net.URL;

import org.geotools.data.ows.WMSCapabilities;
import org.geotools.wms.v1_1_1.bindings.WMSV1_1_1Configuration;
import org.geotools.xml.Parser;

import junit.framework.TestCase;

public class StreamingParserWMSV1_1_1OnlineTest extends TestCase {
	
	
	public void testStreamingWMSV1_1_1Configuration() throws Exception {
		URL server = new URL("http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?VERSION=1.1.0&REQUEST=GetCapabilities&SERVICE=WMS");
        InputStream capInput = server.openStream();
        
        Parser p = new Parser(new WMSV1_1_1Configuration());
        Object o = p.parse(capInput);
        
        assertTrue(o instanceof WMSCapabilities);
		
	}
	

}
