diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2016-11-30 03:51:23 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2016-11-30 03:51:23 +0900 |
| commit | 5771c9778e917803adeb6e3f6ab7b0680d10aaa1 (patch) | |
| tree | 6c826df8fa5c05d45efe6bafe730b83310283f76 /mrbgems/mruby-struct | |
| parent | 37743111d98558e6467f9d5e5498031b3300581f (diff) | |
| download | mruby-5771c9778e917803adeb6e3f6ab7b0680d10aaa1.tar.gz mruby-5771c9778e917803adeb6e3f6ab7b0680d10aaa1.zip | |
add a test for #3296
Diffstat (limited to 'mrbgems/mruby-struct')
| -rw-r--r-- | mrbgems/mruby-struct/test/struct.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/mrbgems/mruby-struct/test/struct.rb b/mrbgems/mruby-struct/test/struct.rb index 2fe684960..1c0939e7f 100644 --- a/mrbgems/mruby-struct/test/struct.rb +++ b/mrbgems/mruby-struct/test/struct.rb @@ -187,3 +187,13 @@ assert("Struct.new does not allow array") do Struct.new("Test", [:a]) end end + +assert("Struct.new generates subclass of Struct") do + begin + original_struct = Struct + Struct = String + assert_equal original_struct, original_struct.new.superclass + ensure + Struct = original_struct + end +end |
