Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing documentation not correct #957

Open
petertellgren opened this issue Jun 15, 2021 · 4 comments
Open

Testing documentation not correct #957

petertellgren opened this issue Jun 15, 2021 · 4 comments

Comments

@petertellgren
Copy link

Bug report

When I tried to use the Savon::SpecHelper I could not get it to work so I resorted to setting up an example
project following the documentation found here.
Unfortunately following the docs I ran into other issues rather than my real project issues so I thought I'd raise them here to see if we can help fix the documentation and eventually get to my real problem :)

Current behavior:

  1. Running code from Testing documentation results in ArugmentError
  2. Addressing Argument Error causes NoMethodError

Steps to reproduce current behavior:
to reproduce the initial error:

git clone [email protected]:petertellgren/savon-spec-bug.git
cd savon-spec-bug
bundle install
bundle exec rspec

to reproduce the subsequent error:

git checkout step-2
bundle exec rspec

Expected behavior:
Passing tests

System information:

  • ruby version: 2.7.3
  • savon version: 2.12.1
@olleolleolle
Copy link
Contributor

👋 There is a repo https://github.com/savonrb/savonrb.github.io which has the text for the website.

Any output examples you can offer in the Description would help people wanting to help out fixing this!

@olleolleolle
Copy link
Contributor

https://github.com/savonrb/savonrb.github.io/blob/master/version2/testing.md this is the page

Now I have attempted to run the example.

The step-2 branch is using the correct arguments, the first Symbol being the name of an operation to call on the WSDL-located service.


 def authenticate(message)
   @client.call(:authenticate, message: message)
 end

Now, the WSDL document describing operations is not valid, that is, "http://example.com?wsdl" being passed to the client, it needs to be a real WSDL description of operations. The text is perhaps not clear about the fact that that line is a non-functioning example WSDL.

The docs could need updating with:

  • FIX a note about which "operation" to run from the WSDL, avoiding the ArgumentError
  • perhaps a note about the fixture XML files with expected results

@stale
Copy link

stale bot commented Jan 8, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jan 8, 2022
@benjamin-ltr
Copy link

it needs to be a real WSDL description of operations

Thanks for this message, I was indeed not really aware of it and lost half an hour.

@stale stale bot removed the stale label Jan 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants