marceldegraaf/sisow — Issue #2: Sisow::Issuer.list - error in testmode
Author: emiellohr
Created: 2012-02-15 09:40:59+00:00
State: open

Hi Marcel,

the Sisow::Issuer.list raises the following error in testmode:

Loading development environment (Rails 3.1.1)
ruby-1.9.2-p136 :001 > Sisow::Issuer.list
opening connection to www.sisow.nl...
opened
<- "GET /Sisow/iDeal/RestHandler.ashx/DirectoryRequest?merchantid=2537397334&merchantkey=3e66884ff0898940a715e1b0c50221788f8a21d1&test=true HTTP/1.1\r\nConnection: close\r\nHost: www.sisow.nl\r\n\r\n"
-> "HTTP/1.1 200 OK\r\n"
-> "Cache-Control: private\r\n"
-> "Content-Type: text/xml; charset=utf-8\r\n"
-> "Server: Microsoft-IIS/7.0\r\n"
-> "X-AspNet-Version: 2.0.50727\r\n"
-> "X-Powered-By: ASP.NET\r\n"
-> "Date: Wed, 15 Feb 2012 09:37:10 GMT\r\n"
-> "Connection: close\r\n"
-> "Content-Length: 238\r\n"
-> "\r\n"
reading 238 bytes...
-> "99Sisow Bank (test)"
read 238 bytes
Conn close
NoMethodError: undefined method `issuerid' for ["issuerid", "99"]:Array
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/bundler/gems/sisow-e5f952cee494/lib/sisow/issuer.rb:10:in `block in list'
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/bundler/gems/sisow-e5f952cee494/lib/sisow/issuer.rb:8:in `each'
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/bundler/gems/sisow-e5f952cee494/lib/sisow/issuer.rb:8:in `map'
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/bundler/gems/sisow-e5f952cee494/lib/sisow/issuer.rb:8:in `list'
from (irb):1
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/gems/railties-3.1.1/lib/rails/commands/console.rb:45:in `start'
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/gems/railties-3.1.1/lib/rails/commands/console.rb:8:in `start'
from /home/elohr/.rvm/gems/ruby-1.9.2-p136/gems/railties-3.1.1/lib/rails/commands.rb:40:in `'
from script/rails:6:in `require'
from script/rails:6:in `

'

In production mode it works fine.