Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Ticket #377 (defect)

Opened 3 years ago

Last modified 3 years ago

test_xmlrpc_filter FAILED when running test.py --serverless

Status: closed (fixed)

Reported by: fumanchu Assigned to: dowski
Priority: normal Milestone: 2.2-beta
Component: CherryPy code Keywords: test
Cc:
C:\Python23\Lib\site-packages>python cherrypy\test\test.py --serverless --test_xmlrpc_filter
Python version used to run this test script: 2.3.2
CherryPy version 2.1.0


Running tests: Serverless
test_0_NormalStateFlow (test_states.ServerStateTests) ... ok
test_1_Restart (test_states.ServerStateTests) ... ok
test_2_KeyboardInterrupt (test_states.ServerStateTests) ... ok
testXmlRpcFilter (test_xmlrpc_filter.XmlRpcFilterTest) ... ERROR

======================================================================
ERROR: testXmlRpcFilter (test_xmlrpc_filter.XmlRpcFilterTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Python23\Lib\site-packages\cherrypy\test\test_xmlrpc_filter.py", line 103, in testXmlRpcFilter
    self.assertEqual(proxy.return_single_item_list(),
  File "C:\Python23\lib\xmlrpclib.py", line 1029, in __call__
    return self.__send(self.__name, args)
  File "C:\Python23\lib\xmlrpclib.py", line 1316, in __request
    verbose=self.__verbose
  File "C:\Python23\lib\xmlrpclib.py", line 1062, in request
    self.send_content(h, request_body)
  File "C:\Python23\lib\xmlrpclib.py", line 1176, in send_content
    connection.endheaders()
  File "C:\Python23\lib\httplib.py", line 712, in endheaders
    self._send_output()
  File "C:\Python23\lib\httplib.py", line 597, in _send_output
    self.send(msg)
  File "C:\Python23\lib\httplib.py", line 564, in send
    self.connect()
  File "C:\Python23\lib\httplib.py", line 548, in connect
    raise socket.error, msg
error: (10061, 'Connection refused')

FAILED (errors=1)

hit enter

Change History

10/29/05 21:47:18: Modified by dowski

  • owner changed from rdelon to dowski.

That's because it is using xmlrpclib.ServerProxy to call the methods in the test. It uses a real host:port connection to the server in order to issue the xmlrpc requests.

It looks like xmlrpc request bodies can be built easy enough with xmlrpclib.dumps() and then posted to CP using the test framework. If it is done that way it should work serverless.

10/29/05 21:47:27: Modified by dowski

  • status changed from new to assigned.

11/09/05 22:04:26: Modified by dowski

  • status changed from assigned to closed.
  • resolution set to fixed.
  • milestone set to 2.2-beta.

Fixed in [804].

Hosted by WebFaction

Log in as guest/cpguest to create tickets