spec/spec_helper.rb in twilio-ruby-5.6.4 vs spec/spec_helper.rb in twilio-ruby-5.7.0
- old
+ new
@@ -8,10 +8,12 @@
require_relative './holodeck/holodeck.rb'
require_relative './holodeck/hologram.rb'
require 'twilio-ruby'
require 'rack'
+require 'rspec/matchers'
+require 'equivalent-xml'
RSpec.configure do |config|
config.expect_with :rspec do |c|
c.syntax = :expect
end
@@ -27,6 +29,10 @@
ENV['ACCOUNT_SID']
end
def auth_token
ENV['AUTH_TOKEN']
+end
+
+def parse(twiml_response)
+ Nokogiri::XML::Document.parse(twiml_response.to_s, &:noblanks)
end