Unable to attach test reporter to test framework or test framework quit unexpectedly

Hello...I am getting the error below when using RubyMine 4.5.4 or 5.0.2 when running Cucumber tests.  I have ruby 193 build 392 installed along with the tdm devkit.  The tests run from the ruby command prompt ok.  Using cucumber gem 1.2.1.  Does anyone have any ideas regarding what might be causing this?

C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:88:in `join': can't convert nil into String (TypeError)
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:88:in `<class:ConfigFile>'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:36:in `<top (required)>'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/rubygems_integration.rb:4:in `<top (required)>'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/shared_helpers.rb:4:in `<top (required)>'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/setup.rb:1:in `<top (required)>'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'


Here is the code from the config_file.rb.  The error is coming from the last line

system_config_path =
begin
require "etc"
Etc.sysconfdir
rescue LoadError, NoMethodError
begin
# TODO: remove after we drop 1.8.7 and 1.9.1
require 'Win32API'
CSIDL_COMMON_APPDATA = 0x0023
path = 0.chr * 260
if RUBY_VERSION > '1.9' then
SHGetFolderPath = Win32API.new 'shell32', 'SHGetFolderPath', 'PLPLP',
'L', :stdcall
SHGetFolderPath.call nil, CSIDL_COMMON_APPDATA, nil, 1, path
else
SHGetFolderPath = Win32API.new 'shell32', 'SHGetFolderPath', 'LLLLP',
'L'
SHGetFolderPath.call 0, CSIDL_COMMON_APPDATA, 0, 1, path
end
path.strip
rescue LoadError
RbConfig::CONFIG["sysconfdir"] || "/etc"
end
end
# :startdoc:
SYSTEM_WIDE_CONFIG_FILE = File.join system_config_path, 'gemrc'

1 comment

Hi,

it is hard to read such a malformed code as it is rendered i your post (I think gist would provide view of the code)
but I'd say that it looks like system_config_path is nil.  I'd suggest to check result of every SHGetFolderPath() call and see
what exactly is going on in the code.

Regards, Oleg.

0

Please sign in to leave a comment.