Ignore this entry - just trying to fix the code-formatting problems
[Test]
public void ExtendingClass()
{
PythonEngine engine = new PythonEngine();engine.Import("clr");
engine.LoadAssembly(GetType().Assembly);
engine.ExecuteToConsole("from IronPythonLib.Tests import *");engine.Execute(@"class MyTransformer(IStringTransformer):
def Transform(self, input):
return input + "" is now transformed""");IStringTransformer transformer = engine.EvaluateAs
("MyTransformer()");
Assert.AreEqual("input is now transformed", transformer.Transform("input"));
}
hmmm?
edit: seems better now, swapped to a simpler layout though I doub't it will work well for people with lower resolutions... most people will (hopefully) read this via RSS at any rate.
Written on October 1, 2006