Sha256: d6fb0e91ce405fb77d760900f9dcfa2474c94b699777e8f62f73c62a82908b06

Contents?: true

Size: 527 Bytes

Versions: 3

Compression:

Stored size: 527 Bytes

Contents

require 'mirrors'
require 'byebug'

module ClassFixtureModule
end

class ClassFixture
  Foo = "Bar"

  class ClassFixtureNested
    class ClassFixtureNestedNested
    end
  end
  include ClassFixtureModule

  attr_accessor :b
  def a
    @a = 1
    @@cvb = 1
  end

  @@cva = 1
  @civa = 1

  def self.b
    @@cvc = 1
    @civb = 1
  end
end

class ClassFixtureSubclass < ClassFixture; end
class ClassFixtureSubclassSubclass < ClassFixtureSubclass; end

@m = Mirrors.reflect(ClassFixture)
puts "Foo" == @m.constant("Foo").name

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mirrors-0.0.3 lol.rb
mirrors-0.0.2 lol.rb
mirrors-0.0.1 lol.rb