Esempio n. 1
0
        public void readSingleWord()
        {
            MemoryStream stream = new MemoryStream(Encoding.UTF8.GetBytes("Hello"));
            StreamReader streamReader = new StreamReader(stream);

            IOConsoleIn consoleIn = new EchoConsoleIn(streamReader);
            Assert.AreEqual("Hello", consoleIn.ReadLine());
        }
Esempio n. 2
0
 public static void Main(string[] args)
 {
     IOConsoleIn input = new EchoConsoleIn(Console.In);
     IOConsoleOut output = new EchoConsoleOut(Console.Out);
     new EchoServer(input, output).Start();
 }