diff options
| author | Seba Gamboa <[email protected]> | 2015-09-25 18:01:14 -0300 |
|---|---|---|
| committer | Seba Gamboa <[email protected]> | 2015-09-25 18:01:14 -0300 |
| commit | 3a60c88a3b3dbd334e4769a6283fb90c0495c25b (patch) | |
| tree | de3d8ec187771d6e2d5f42da864c19ee6d69d890 /spec/handlers/c/class_handler_spec.rb | |
| parent | 82e906d74dcc943d737ced7a6ebfee1e71a74aaf (diff) | |
| download | yard-mruby-3a60c88a3b3dbd334e4769a6283fb90c0495c25b.tar.gz yard-mruby-3a60c88a3b3dbd334e4769a6283fb90c0495c25b.zip | |
Sorting tons of stuff around
Diffstat (limited to 'spec/handlers/c/class_handler_spec.rb')
| -rw-r--r-- | spec/handlers/c/class_handler_spec.rb | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/spec/handlers/c/class_handler_spec.rb b/spec/handlers/c/class_handler_spec.rb deleted file mode 100644 index 9428dd6..0000000 --- a/spec/handlers/c/class_handler_spec.rb +++ /dev/null @@ -1,41 +0,0 @@ -require_relative 'spec_helper' - -describe YARD::MRuby::Handlers::C::ClassHandler do - it "should register classes" do - parse_init 'cFoo = mrb_define_class(mrb, "Foo", mrb->object_class);' - - expect(Registry.at('Foo').type).to be :class - end - - it "should register classes under namespaces" do - parse_init 'cFoo = mrb_define_class_under(mrb, cBar, "Foo", rb_cObject);' - expect(Registry.at('Bar::Foo').type).to be :class - end - - it "should remember symbol defined with class" do - parse_init(<<-eof) - cXYZ = mrb_define_class(mrb, "Foo", mrb->object_class); - mrb_define_method(mrb, cXYZ, "bar", bar, MRB_ARGS_NONE()); - eof - expect(Registry.at('Foo').type).to be :class - expect(Registry.at('Foo#bar')).not_to be_nil - end - - it "should lookup superclass symbol name" do - parse_init(<<-eof) - cXYZ = mrb_define_class(mrb,"Foo", mrb->object_class); - cBar = mrb_define_class(mrb,"Bar", cXYZ); - eof - expect(Registry.at('Bar').superclass).to eq Registry.at('Foo') - end - - it "should associate declaration comments as class docstring" do - parse_init(<<-eof) - /* Docstring! */ - cFoo = mrb_define_class(mrb, "Foo", mrb->object_class); - eof - - expect(Registry.at('Foo').docstring).not_to be_blank - end - -end |
