[owslib-devel] tests intro

Jachym Cepicky jachym.cepicky at gmail.com
Tue Apr 3 14:18:10 PDT 2012


I have also noticed, that URL must be given, when constructing the e.g.
WFS object

w = WebFeatureService(xml="file") is not possible, must be

w = WebFeatureService(url,xml="file") where "url" must point to existing
service

not sure, if that is propper behaviour

best way would be to setup solid state custom "owslib's" services .. but
where and who will maintain them? We have the same problem in pywps too

thanks for tests intro

J

On 2.4.2012 15:55, Dominic Lowe wrote:
> And yes your proposal to reduce the use of live URLs sounds good, except how do you test operations that don't return XML, such as getMap, getCoverage etc?
> 
> 
> 
> On 02/04/12 14:49, dominic.lowe at stfc.ac.uk wrote:
>> Hi Jachym
>>
>> I use:
>> python runalldoctests.py
>>
>> and for a single test:
>> python runalldoctests.py -t wms_JPLCapabilities.txt
>>
>> But you're right, most of them fail now due to reliance on old services.
>>
>> Cheers
>> Dom
>>
>>
>>
>> On 31/03/12 22:01, jachym.cepicky at gmail.com wrote:
>>> Hi,
>>>
>>> could anybody give me short intro about how the tests in owslib are
>>> structured and how they should be used?
>>>
>>> I have tried:
>>>
>>> cd  tests
>>> sh rundoctests.dist
>>>
>>> And ended up with 16 errors.
>>>
>>> Any way, how to run each test separately, than in a batch?
>>>
>>> And: My experience shows, that using URLs in service testing is
>>> dangerous and leads often to non working tests. The tests should IMHO
>>> not be about testing, weather some service is alive (what is actually
>>> tested), but parsing capabilities of returned XML (what we need to test).
>>>
>>> Proposal: instead of testing URLs, each test should be constructed, so
>>> it loads file stored at the harddrive and then it will be parsed. In
>>> this way, we are also more flexible in test constructions, because we
>>> can add certain elements to XML files according to what needs to be
>>> tested "by hand" and we would not be dependent on external services.
>>>
>>> I have a feeling, that at least dozen of my fails are caused by that the
>>> http://ndg3beta.badc.rl.ac.uk/cows/demo_hadcm3/wfs? is no longer available.
>>>
>>> Any opinion?
>>>
>>> Jachym
> 

-- 
Jachym Cepicky
Help Service - Remote Sensing s.r.o.
jachym.cepicky at gmail.com | jachym at hsrs.cz
http://les-ejk.cz | http://bnhelp.cz

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.osgeo.org/pipermail/owslib-devel/attachments/20120403/7ddaecae/attachment.pgp>


More information about the OWSLib-devel mailing list