Re: testing a website from python

2005-09-21 Thread Benji York
Achim Domma (SyynX Solutions GmbH) wrote: > Benji York wrote: >>If there is any interest I'll try to package up a stand-alone version in >>the next few days. > > I think that would be a very usefull tool. Currently I'm using httpunit > with Jython but a python only tool would be much nicer. I p

Re: testing a website from python

2005-09-21 Thread Josef Meile
Hi, > I just want to test that a given website is up or not from a python > script. I thought of using wget as an os command. Any better ideas? Here is how I did it: import urllib2 import socket def checkUrl(url, timeout=1): """Checks an url for a python version greater than 2.3.3.

Re: testing a website from python

2005-09-21 Thread Grig Gheorghiu
Achim, Have you looked into twill? It's available at Grig -- http://mail.python.org/mailman/listinfo/python-list

Re: testing a website from python

2005-09-21 Thread Achim Domma (SyynX Solutions GmbH)
Benji York wrote: > If there is any interest I'll try to package up a stand-alone version in > the next few days. I think that would be a very usefull tool. Currently I'm using httpunit with Jython but a python only tool would be much nicer. regards, Achim -- http://mail.python.org/mailman/li

Re: testing a website from python

2005-09-21 Thread Benji York
matt wrote: > Here's something I did recently at work. > It contains unittest code and is using > urllib2. > http://blog.spikesource.com/pyhton_testcases.htm If you want to test web sites, you might be interested in zope.testbrowser (currently Zope 3 only, but fixing that is on my to do list).

Re: testing a website from python

2005-09-20 Thread matt
Here's something I did recently at work. (Thought it's testing http digest authentication, the idea would the same (testNoAuth() is probably doing what you want)). It contains unittest code and is using urllib2. http://blog.spikesource.com/pyhton_testcases.htm matt -- http://mail.python.org/ma

Re: testing a website from python

2005-09-20 Thread Laszlo Zsolt Nagy
M.N.A.Smadi wrote: >hi; > >I just want to test that a given website is up or not from a python >script. I thought of using wget as an os command. Any better ideas? > > urllib http://www.python.org/doc/current/lib/module-urllib.html If you only want to test if the HTTP port is open or not:

testing a website from python

2005-09-20 Thread M.N.A.Smadi
hi; I just want to test that a given website is up or not from a python script. I thought of using wget as an os command. Any better ideas? thanks moe smadi -- http://mail.python.org/mailman/listinfo/python-list