about summary refs log blame commit diff
path: root/IRCSharp.Tests/State/Motd.cs
blob: 3efbce756123e26f7f2b76972edfdb8fbaf1a9e7 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
                                    
                
                
                                                   
 
                              



                     



                                            



                                                                 



                                                                                                                      

     
using System.Collections.Generic;
using IRCStates;
using IRCTokens;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace IRCSharp.Tests.State
{
    [TestClass]
    public class Motd
    {
        [TestMethod]
        public void MessageOfTheDay()
        {
            var server = new Server("test");
            server.Parse(new Line("001 nickname"));
            server.Parse(new Line("375 * :start of motd"));
            server.Parse(new Line("372 * :first line of motd"));
            server.Parse(new Line("372 * :second line of motd"));

            CollectionAssert.AreEqual(new List<string> {"start of motd", "first line of motd", "second line of motd"},
                server.Motd);
        }
    }
}