tenderlove (owner)

Revisions

gist: 192148 Download_button fork
public
Public Clone URL: git://gist.github.com/192148.git
Embed All Files: show embed
Ruby #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
  def test_method_call
    x = Class.new {
      attr_reader :called
      def initialize
        @called = false
      end
 
      def hello
        @called = true
      end
    }.new
    @rt['x'] = x
    @rt.eval('$x->hello();')
    assert x.called
  end