Exemplo n.º 1
0
        private static void Main(string[] args)
        {
            var renderer = new Renderer();
            var inputHandler = new InputHandler();

            var engine = new Engine(renderer, inputHandler);
            engine.Run();
        }
Exemplo n.º 2
0
        public void IsEngineConstructorMakeInstanceOfEngine()
        {
            var renderer = new Renderer();
            var input = new InputHandler();
            var engine = new Engine(renderer, input);

            Assert.IsInstanceOfType(engine, typeof(Engine));
        }
Exemplo n.º 3
0
        public void IsRendererPrintRightMessageWithNoMessage()
        {
            List<string> outLines = new List<string>();
            var mockWriter = new Mock<TextWriter>();
            mockWriter.Setup(writer => writer.WriteLine(It.IsAny<string>()))
                    .Callback<string>(s => outLines.Add(s));
            Console.SetOut(mockWriter.Object);

            var render = new Renderer();
            render.RenderMessage();

            Assert.AreEqual(0, outLines.Count);
        }
Exemplo n.º 4
0
 public void IsEngineRunRight()
 {
     var renderer = new Renderer();
     Assert.IsInstanceOfType(renderer, typeof(Renderer));
 }
Exemplo n.º 5
0
 public void IsEngineMakeStandartGameRules()
 {
     var renderer = new Renderer();
     var input = new InputHandler();
     var engine = new Engine(renderer, input);
 }