diff options
| author | dreamedge <[email protected]> | 2014-07-18 09:50:54 +0900 |
|---|---|---|
| committer | dreamedge <[email protected]> | 2014-07-18 09:50:54 +0900 |
| commit | 0b8a0f4bb48e33c58b738fc96a7d4130b7a6ef57 (patch) | |
| tree | 0302abf9e4ca09febb8789c709f3df015a3f4a97 /test/t/module.rb | |
| parent | d17506c176ef6d1ac70e84664790cdb1cb2cf3de (diff) | |
| download | mruby-0b8a0f4bb48e33c58b738fc96a7d4130b7a6ef57.tar.gz mruby-0b8a0f4bb48e33c58b738fc96a7d4130b7a6ef57.zip | |
add Module#module_function
Diffstat (limited to 'test/t/module.rb')
| -rw-r--r-- | test/t/module.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/t/module.rb b/test/t/module.rb index 5ac794330..2e19f350f 100644 --- a/test/t/module.rb +++ b/test/t/module.rb @@ -522,3 +522,13 @@ assert('clone Module') do B.new.foo end + +assert('Module#module_function') do + module M + def modfunc; end + module_function :modfunc + end + + assert_true M.respond_to?(:modfunc) +end + |
