Exemple #1
0
        /// <inheritdoc/>
        public override void WriteMessageTo(MessageWriter writer)
        {
            Comparison c = diffResult.Differences.First().Comparison;

            writer.WriteMessageLine(comparisonFormatter.GetDescription(c));
            if (diffResult.TestSource.SystemId != null ||
                diffResult.ControlSource.SystemId != null)
            {
                writer.WriteMessageLine(string.Format("comparing {0} to {1}",
                                                      diffResult.TestSource.SystemId,
                                                      diffResult.ControlSource.SystemId));
            }
            writer.DisplayDifferences(GetDetails(c.ControlDetails, c.Type),
                                      GetDetails(c.TestDetails, c.Type));
        }
Exemple #2
0
 /// <summary>
 /// Returns a string representation of this comparison using the
 /// given IComparisonFormatter.
 /// <param name="formatter"> the IComparisonFormatter to use</param>
 /// <return>a string representation of this comparison</return>
 /// </summary>
 public string ToString(IComparisonFormatter formatter)
 {
     return(formatter.GetDescription(this));
 }