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

PythonInterop_InvokeMember_Fallback1() public method

Python falls back if the member is not defined and Ruby then invokes the member with original casing.
public PythonInterop_InvokeMember_Fallback1 ( ) : void
return void
        public void PythonInterop_InvokeMember_Fallback1() {
            if (!_driver.RunPython) return;

            var py = Runtime.GetEngine("python");
            ScriptScope scope = py.CreateScope();
            py.Execute(@"class C: pass", scope);

            XAssertOutput(() => 
                Engine.Execute(@"
class Object
  def Foo 
    puts 'Object::Foo'
  end

  def bar
    puts 'Object::bar'
  end
end

#c.new.foo rescue p $!
c.new.bar
", scope), @"

"
 );
        }
Tests