def test_deserialize(self): from spyne.protocol.soap import Soap11 class SomeService(ServiceBase): @srpc(Integer, _returns=Iterable(Integer)) def some_call(yo): return range(yo) app = Application([SomeService], 'tns', in_protocol=Soap11(), out_protocol=Soap11()) meat = 30 string = """ <x:Envelope xmlns:x="http://schemas.xmlsoap.org/soap/envelope/"> <x:Body> <tns:some_call xmlns:tns="tns"> <tns:yo>%s</tns:yo> </tns:some_call> </x:Body> </x:Envelope> """ % meat obj = deserialize_request_string(string, app) assert obj.yo == meat