public GetCommand ( string commandName ) : ICommand | ||
commandName | string | The name of the command to retrieve. |
Результат | ICommand |
public void Should_Be_Able_To_Retrieve_Null_For_An_Unknown_Command() { var cmdRepository = new CommandRepository(); ICommand results = cmdRepository.GetCommand("ThisIsNotACommand"); Assert.IsNull(results); }
public void Should_Be_Able_To_Retrieve_A_Command_By_CommandName() { var cmdRepository = new CommandRepository(); ICommand results = cmdRepository.GetCommand("TestCommand"); Assert.IsNotNull(results); Assert.IsTrue(results is MockCommand1); }