예제 #1
0
        private static void WriteResult(ResultCheck resultCheck
                                        , string resultFileName
                                        , string comparisonResult
                                        , string executionValue)
        {
            var context   = new ContextForAutoTest();
            var resultStr = new AutoTestResult();

            resultStr.ExpectedContent    = resultCheck.Description;
            resultStr.ConfirmationTarget = SetConfirmationTaget(resultCheck);
            resultStr.ExpectedValue      = resultCheck.ExpectedValue;
            resultStr.ExecutionValue     = executionValue;
            resultStr.ComparisonResult   = comparisonResult;
            WriteResult(resultString: resultStr, ResultFileName: resultFileName);
            WriteLog(
                logFileName: Parameters.ExtendedAutoTestSettings.LogFileName,
                logMessage:
                Displays.AutoTestResultMessage(
                    context: context,
                    data: new string[]
            {
                resultStr.ComparisonResult,
                resultStr.ExpectedContent,
                resultStr.ConfirmationTarget,
                resultStr.ExpectedValue,
                resultStr.ExecutionValue
            }),
                consoleColor: SelectConsoleColor(resultStr.ComparisonResult)
                );
        }