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

Unable to run tests on Windows #43

Open
lollerific opened this issue Jan 31, 2011 · 2 comments
Open

Unable to run tests on Windows #43

lollerific opened this issue Jan 31, 2011 · 2 comments
Labels

Comments

@lollerific
Copy link

I wrote a patch (modified autoload/ruby_debugger.vim) to make debugging RSpec tests work, as there was an issue with the get_escaped_absolute_path(command) method in ruby_debugger.vim. I assume this will also work for Cucumber features and Unit::Test but I want to run the vim-ruby-debugger unit tests to confirm. However, when I try to run them on Windows I get the following error:

E121: Undefined variable: g:TU

By the way, the patch is replacing the following lines (around line 111) with my changes.

Original (line 111 of autoload/ruby_debugger.vim)
if given_path[0] == '/'
let absolute_path = given_path

Updated:
let is_windows = (has("win32") || has("win64"))
let is_windows_start_path = (given_path =~ '' || given_path =~ '^\w:(|/)')
let is_windows_absolute_path = is_windows && is_windows_start_path
if given_path[0] == '/' || is_windows_absolute_path
let absolute_path = given_path

This change will have to be applied to both autoload/ruby_debugger.vim and additionals/ruby_debugger.vim (as its the file that declares the g:TU variable). I can't quite figure out why running the vim-ruby-debugger test cases isn't working...

@astashov
Copy link
Owner

astashov commented Feb 1, 2011

Oh, great! I actually even don't have Windows now, and I can't check it. Could you please create a pull request with that patch for me (or maybe even a git patch)?

@astashov
Copy link
Owner

astashov commented Feb 1, 2011

And about undefined variable - g:TU - run :Rdebugger first, to load autoload/ruby_debugger.vim. An then - call g:TU.run().

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

No branches or pull requests

2 participants