/** <inheritDoc /> */ protected override void CheckResult(object res) { Assert.IsTrue(res != null); PortableResult res0 = res as PortableResult; Assert.IsTrue(res0 != null); Assert.AreEqual(1, res0.Res); }
public void TestTaskResultPortable() { TestTask <PortableResult> task = new TestTask <PortableResult>(); PortableResult val = new PortableResult(100); PortableResult res = Grid1.Compute().Execute(task, new Tuple <bool, PortableResult>(true, val)); Assert.AreEqual(val.Val, res.Val); val.Val = 101; res = Grid1.Compute().Execute(task, new Tuple <bool, PortableResult>(false, val)); Assert.AreEqual(val.Val, res.Val); }