public void CustomCommandCollectionCanAddCommand() { collection.AddCommand("test", "data"); Assert.That(collection.ContainsCommand("test"), Is.True); Assert.That(collection.Commands.ContainsKey("test")); Assert.That(collection.Commands["test"].Text, Is.EqualTo("data")); }
public async Task CustomChatCommandCanRemoveCommands() { collection.AddCommand("test", "sub"); Assert.That(collection.ContainsCommand("test"), Is.True); var data = new ChatCommandData("command", new[] { "remove", "test" }); await command.Process(chat, data); Assert.That(collection.ContainsCommand("test"), Is.False); }