public void OriginNickOnly() { string origin = "puckipedia"; IRCMessageOrigin parsed = new IRCMessageOrigin(origin); Assert.AreEqual(parsed.Nick, "puckipedia", "Nick parsed incorrectly"); Assert.AreEqual(parsed.Host, null, "Parsed a host"); Assert.AreEqual(parsed.User, null, "Parsed a user"); Assert.AreEqual(origin, parsed.ToString(), "ToString gave wrong answer"); }
public void OriginHostOnly() { string origin = "irc.puckipedia.com"; IRCMessageOrigin parsed = new IRCMessageOrigin(origin); Assert.AreEqual(parsed.Nick, null, "Parsed a nick"); Assert.AreEqual(parsed.Host, "irc.puckipedia.com", "Host parsed incorrectly"); Assert.AreEqual(parsed.User, null, "Parsed a user"); Assert.AreEqual(origin, parsed.ToString(), "ToString gave wrong answer"); }