/// <summary> /// Shows setting Host OM on globals so that dynamic languages /// can import, require, etc., to access the host's OM. /// </summary> public static void Scenario_ExecuteFile_Push() { var hostOM = new MyHostObjectModel(); var runtime = ScriptRuntime.CreateFromConfiguration(); runtime.Globals.SetVariable("App", hostOM); runtime.ExecuteFile("register_user_commands.py"); hostOM.UserCommands["foo"](); }