Skip to content

Instantly share code, notes, and snippets.

@deependersingla
Created December 11, 2013 09:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deependersingla/7907692 to your computer and use it in GitHub Desktop.
Save deependersingla/7907692 to your computer and use it in GitHub Desktop.
it 'should take care of corner cases like mongo[] e.g Foo::Bar.new[]- issue 998' do
klass = Class.new { def []; :hello; end }
meth = Pry::Method.from_str("klass.new[]", Pry.binding_for(binding))
meth.name.should == "[]"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment