IronRuby.Tests.Tests.ModuleSingletons1 C# (CSharp) Method

ModuleSingletons1() public method

Singleton(module)'s super-class is singleton(Module).
public ModuleSingletons1 ( ) : void
return void
        public void ModuleSingletons1() {
            TestOutput(@"
class Class
  def self.c_c
    :c_c
  end 
end

class Module
  def self.c_m
    :c_m
  end 
end

module M
  class << self
    $SM = self
  end  
end 

$SM.method(:c_c) rescue p $!
$SM.c_c rescue p $!

p $SM.c_m
", @"
#<NameError: undefined method `c_c' for class `Class'>
#<NoMethodError: undefined method `c_c' for #<Class:M>>
:c_m
");
        }
Tests