public void should_display_help() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!help", "Bob"); plugin.Evaluate(pl).Should().Contain("the commands I know"); plugin.Evaluate(pl).Should().Contain("!slap [thing]"); Debug.Write(plugin.Evaluate(pl)); }
public void should_hug_with_default() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!hug", "Bob"); plugin.Evaluate(pl).Should().Be("Bob hugs himself"); }
public void should_hug_with_all_args() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!hug Jim and his monkey", "Bob"); plugin.Evaluate(pl).Should().Be("Bob hugs Jim and his monkey"); }
public void should_display_directory() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!dir", "Bob"); var result = plugin.Evaluate(pl); Debug.WriteLine(result); result.Should().Contain("Directory:"); }
public void scramble() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!scramble", "Bob"); var result = plugin.Evaluate(pl); Debug.WriteLine(result); result.Should().Contain("B"); result.Should().Contain("o"); result.Should().Contain("b"); result.Trim().Length.Should().Be(3); }
public void should_respond_with_slowclap_image_url() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!slowclap", "Bob"); plugin.Evaluate(pl).Should().Be("http://i.imgur.com/r7ZNHvz.gif"); }
public void weather() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!temp", "Bob"); var result = plugin.Evaluate(pl); Debug.WriteLine(result); result.Should().Contain("F"); result.Should().Contain("C)"); }
public void should_smack_with_default() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!smack", "Bob"); plugin.Evaluate(pl).Should().Be("Bob smacks himself around with a large trout"); }
public void should_smack_with_all_args() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!smack Jim and his monkey", "Bob"); plugin.Evaluate(pl).Should().Be("Bob smacks Jim and his monkey around with a large trout"); }
public void should_slap_with_first_arg() { var plugin = new CommandPlugin(); var pl = new ParsedLine("!slap Jim", "Bob"); plugin.Evaluate(pl).Should().Be("Bob slaps Jim"); }