Is this a new application? The reason I ask is because I would NEVER
use XML if I could avoid it. If it's a new application and you have
control over the API, use JSON instead. It's easier to work with and
it parses faster.
Best,
Paul
> --
> You received this message because you are subscribed to the Google Groups "Service Oriented Design With Ruby" group.
> To post to this group, send email to service-oriented...@googlegroups.com.
> To unsubscribe from this group, send email to service-oriented-desig...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/service-oriented-design-with-ruby?hl=en.
>
>
+1 (and more if I have spare karma)
-J.
> Best,
> Paul
>
> On Mon, Apr 11, 2011 at 9:51 AM, rgagnon <rem.g...@gmail.com> wrote:
> > Hello,
> >
> > I bought the book Service Oriented Design with ruby and rails and we
> > are about to create some web services. ?We want to start it the right
> > way.
> >
> > Here is my question :
> >
> > My web service will receive an xml as the request that we need to
> > parse or add or change some stuffs in it and call an external service
> > with it. ?We will do same thing with the response(parsing, add or
> > change stuff) then return it back to the caller in a internal standard
> > response. ?The xml has to be in the body on as form field xml_field
> > for instance?
> >
> > If its in the body, to test it in rspec, we need to pass it like
> > this ? :
> >
> > request.env['RAW_POST_DATA'] = '<test>test</test>'
> >
> > Suggestions?
> >
> > Our server is with rails 3.
> >
> > Thank for the great book btw.
> >
> > --
> > You received this message because you are subscribed to the Google Groups "Service Oriented Design With Ruby" group.
> > To post to this group, send email to service-oriented...@googlegroups.com.
> > To unsubscribe from this group, send email to service-oriented-desig...@googlegroups.com.
> > For more options, visit this group at http://groups.google.com/group/service-oriented-design-with-ruby?hl=en.
> >
> >
>
> --
> You received this message because you are subscribed to the Google Groups "Service Oriented Design With Ruby" group.
> To post to this group, send email to service-oriented...@googlegroups.com.
> To unsubscribe from this group, send email to service-oriented-desig...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/service-oriented-design-with-ruby?hl=en.
>
--
Jason Dixon
DixonGroup Consulting
http://www.dixongroup.net/
describe EnqueteCreditController do
describe "Requête avec réponse valide" do
it "should be successful" do
request.env['content_type'] = 'application/xml'
request.env['RAW_POST_DATA'] = '<enquete><id>1</id></enquete>'
post :create, :format => :xml
response.should be_success
end
end
end