diff options
Diffstat (limited to 'spec/handlers/c/header/function_handler_spec.rb')
| -rw-r--r-- | spec/handlers/c/header/function_handler_spec.rb | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/spec/handlers/c/header/function_handler_spec.rb b/spec/handlers/c/header/function_handler_spec.rb index 1919fde..5fc56df 100644 --- a/spec/handlers/c/header/function_handler_spec.rb +++ b/spec/handlers/c/header/function_handler_spec.rb @@ -23,19 +23,16 @@ describe YARD::MRuby::Handlers::C::Header::FunctionHandler do MRB_API mrb_value mrb_foo( void ); eof - expect(subject.tag(:return).types).to eq ['mrb_value'] + expect(subject.return_type).to eq 'mrb_value' end - it "should keep return type independently from docs" do + it "should store argument types" do header_line <<-eof - /** - * @return DOCSTRING - */ - MRB_API mrb_value mrb_foo( void ); + MRB_API mrb_value mrb_foo( mrb_state *mrb, mrb_value bar ); eof - expect(subject.tag(:return).text).to eq 'DOCSTRING' - expect(subject.tag(:return).types).to eq ['mrb_value'] + expect(subject.parameter_types.first.type).to eq 'mrb_state *' + expect(subject.parameter_types.last.type).to eq 'mrb_value' + expect(subject.parameter_types.last.name).to eq 'bar' end - end |
