PageRenderTime 25ms CodeModel.GetById 1ms RepoModel.GetById 0ms app.codeStats 0ms

/vendor/gems/facets-2.4.5/test/core/module/test_nesting.rb

https://bitbucket.org/mediashelf/fedora-migrator
Ruby | 21 lines | 16 code | 5 blank | 0 comment | 0 complexity | e7485ec4ac76f2a5f60ba77546c7d51d MD5 | raw file
Possible License(s): GPL-3.0, GPL-2.0, IPL-1.0, AGPL-1.0, LGPL-3.0
  1. require 'facets/module/nesting.rb'
  2. require 'test/unit'
  3. class TestModuleNesting < Test::Unit::TestCase
  4. module M
  5. module N
  6. class C
  7. def n
  8. self.class.nesting
  9. end
  10. end
  11. end
  12. end
  13. def test_nesting
  14. assert_equal( [TestModuleNesting, M, M::N, M::N::C], M::N::C.new.n )
  15. end
  16. end