On 3/29/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Hi
>      I 'm trying to test django app using built-in django unit
> testing. Some of it make a call to xml-rpc server using xmlrpclib.
> Now, I use django testing framework and can run unit testing except
> that I can't enable in-process xml-rpc server.
>
>      My idea is, create xml-rpc server mock as a part of project and
> config to enable it if we run unit test . This can be done using
> separate settings file from production setting. The problem is, every
> xml-rpc call (to in-process xml-rpc mock server) raise 10061
> 'Connection refused'. For twill xml-rpc intercept, it has
> httpconnection to connect calling to in-process server. I don't sure
> if it is an issue here.

Hi Chatchai,

The test server is very much single threaded, so if a view is making
an XML-RPC (or any other AJAX) call on itself, Django won't be able to
respond - this may manifest as a Connection Refused error (depending
on your platform).

There is a ticket (#2879) to add the ability for a live test server to
be running in a separate thread, which should fix this sort of
problem. Addressing this ticket is on my list of things to do. I
haven't looked into the patch attached to the ticket in great depth.
If you are so inclined, feel free to play with the patch and report
back. Testing out patches like this one is one area where the
community can really help out with the development of Django.

Yours,
Russ Magee %-)

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to