protected void Setup(string input) { console = new TestConsole(input); testInst = AppInstance.Get().ForTests((method, argTypes, args) => { var call = new object[] { console, console.In, console.Out }.Select(x => new { t = x, m = x.GetType().GetMethod(method, argTypes) }).Where(x => x.m != null).First(); return(call.m.Invoke(call.t, args)); }); }
static void Main(string[] args) { AppInstance.Get().DoMain(IOMain); }