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

Spec class should be as flexible as Twilio class #13

Open
martinstreicher opened this issue Nov 4, 2014 · 2 comments
Open

Spec class should be as flexible as Twilio class #13

martinstreicher opened this issue Nov 4, 2014 · 2 comments

Comments

@martinstreicher
Copy link

@client = Twilio::REST::Client.new account_sid, auth_token

# alternatively, you can preconfigure the client like so
Twilio.configure do |config|
  config.account_sid = account_sid
  config.auth_token = auth_token
end

# and then you can create a new client without parameters
@client = Twilio::REST::Client.new

However, the sms-spec entry point for Client.new requires arguments. So if you use the convenience code above, things break when including the test tool.

@martinstreicher
Copy link
Author

 1) Sms::Message Instance Methods #send returns a Twilio result
     Failure/Error: message = described_class.send message: :message, number: cell_number
     ArgumentError:
       wrong number of arguments (0 for 2)
     # /Users/mss67/.rvm/gems/ruby-2.1.2@dusk/gems/sms-spec-0.1.7/lib/sms_spec/drivers/twilio-ruby.rb:3:in `initialize'

@rosskevin
Copy link

My pull request solves this:

#20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants