public void TestRetainRelease () { ICommand command = new CommandWithExecute (); Assert.IsFalse (command.retain); command.Retain (); Assert.IsTrue (command.retain); command.Release (); Assert.IsFalse (command.retain); }
public void TestSuccessfulExecute () { ICommand command = new CommandWithExecute (); TestDelegate testDelegate = delegate() { command.Execute(); }; Assert.DoesNotThrow (testDelegate); }
public void TestRetainRelease() { ICommand command = new CommandWithExecute(); Assert.IsFalse(command.retain); command.Retain(); Assert.IsTrue(command.retain); command.Release(); Assert.IsFalse(command.retain); }
public void TestSuccessfulExecute() { ICommand command = new CommandWithExecute(); TestDelegate testDelegate = delegate() { command.Execute(); }; Assert.DoesNotThrow(testDelegate); }