mirror of
1
0
Fork 0
ultimate-vim/sources_non_forked/vim-ruby/spec/indent/method_definitions_spec.rb

41 lines
687 B
Ruby
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

require 'spec_helper'
describe "Indenting" do
specify "method definitions prefixed with access modifiers" do
assert_correct_indenting <<~EOF
class Foo
public def one(x)
end
private def two(y)
code
end
end
EOF
end
specify "method definitions prefixed with any method call" do
assert_correct_indenting <<~EOF
class Foo
foobar def one(x)
end
foobar? def one(x)
end
foobar! def one(x)
end
фубар def one(x)
end
foobar
def one(x)
end
FooBar1 def two(y)
code
end
end
EOF
end
end