source: DPPP/kml/csml2kml/python/csml2kml/csml2kml/tests/testUtils.py @ 3693

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/DPPP/kml/csml2kml/python/csml2kml/csml2kml/tests/testUtils.py@3693
Revision 3693, 658 bytes checked in by mkochan, 12 years ago (diff)

Extended csmlGrapher to allow multiple datasets (that is, data served from multiple WFSs).

Line 
1import csml2kml.utils
2
3print 'Script loaded.\nTesting utils.parseTimestamp().'
4
5print csml2kml.utils.parseTimestamp('2001-12-31T24:00:00')
6print csml2kml.utils.parseTimestamp('2001-12-31T24:00:00Z')
7print csml2kml.utils.parseTimestamp('2001-12-31T23:59:59')
8
9print '\nTesting utils.wget().'
10n = 10
11print 'Retrieving ' + str(n) + ' times.'
12for i in range(n):
13    content = csml2kml.utils.wget('http://bond.badc.rl.ac.uk:8084/geoserver/wfs?request=getFeature&version=1.1.0&typename=np:Station&maxFeatures=2')
14    if content:
15        # print content
16        print 'Retrieval successful (edit testUtils.py to see it).'
17    else:
18        print 'Retrieval error.'
Note: See TracBrowser for help on using the repository browser.