public void CanRegisterCommand() { ChatCommandRouter ccr = new ChatCommandRouter(); ChatCommand cmd = new PrintCommand(); ccr.Register(cmd, null); Assert.AreSame(cmd, ccr.GetCommand(cmd.CommandAliases()[0]).Item1); }
public void CanGetCommand() { ChatCommandRouter ccr = new ChatCommandRouter(); ChatCommand cmd = new PrintCommand(); ccr.Register(cmd, null); ChatCommand retrievedCmd = ccr.GetCommand(cmd.CommandAliases()[0]).Item1; Assert.AreSame(cmd, retrievedCmd); }