public void ExpectGetPrintFrameOfPrintDecoratorNotToBeEmptyString()
        {
            var matrix = new MatrixFactory().CreateMatrix(MatrixTypes.BIG);

            var player = new Player();

            var printer = new PrinterLightMode();
            var standartPrinter = new StandardPrinter();
            printer.SetPrinter(standartPrinter);

            var result = printer.GetPrintFrame(matrix, player);

            Assert.AreNotEqual(result.Length, 0);
        }
        /// <summary>
        /// Takes the "mode" command and process its implementation.
        /// </summary>
        /// <param name="commandInfo">Command used to switch from dark to light mode, and vise versa.</param>
        public override void Execute(ICommandInfo commandInfo)
        {
            if (commandInfo.Params[0] == "light")
            {
                var printerLightMode = new PrinterLightMode();
                printerLightMode.SetPrinter(this.Printer);
                printerLightMode.Apply();
            }
            else if (commandInfo.Params[0] == "dark")
            {
                var printerDarkMode = new PrinterDarkMode();
                printerDarkMode.SetPrinter(this.Printer);
                printerDarkMode.Apply();
            }

            Navigation.ReturnExitNavigation(this.engine, new SecondMenuOptions());
        }
        public void ExpectPrinterLightModeToApplayBlackForegroundColorToConsole()
        {
            var lightPrinter = new PrinterLightMode();
            lightPrinter.Apply();

            var resultColor = Console.ForegroundColor;

            Assert.AreEqual(ConsoleColor.Gray, resultColor);
        }
        public void ExpectSetPrinterNotToThrow()
        {
            var lightPrinter = new PrinterLightMode();
            var darkPrinter = new PrinterDarkMode();

            Assert.DoesNotThrow(() => lightPrinter.SetPrinter(darkPrinter));
        }
        public void ExpectPrintLineOfPrinterDecoratorNotToThrow()
        {
            var lightPrinter = new PrinterLightMode();
            var standartPrinter = new StandardPrinter();

            lightPrinter.SetPrinter(standartPrinter);
            var message = "test message";

            Assert.DoesNotThrow(() => lightPrinter.PrintLine(message));
        }
        public void ExpectPrinterLightModeToApplayWhiteBackgroundToConsole()
        {
            var lightPrinter = new PrinterLightMode();
            lightPrinter.Apply();

            var resultColor = Console.BackgroundColor;

            Assert.AreEqual(ConsoleColor.Black, resultColor);
        }