MsgUtils Class

Summary

Static methods used in creating messages
Namespace
TCLite.Constraints
Base Types
  • object
graph BT Type-->Base0["object"] Type["MsgUtils"] class Type type-node

Syntax

public class MsgUtils

Methods

Name Value Summary
ClipExpectedAndActual(string, string, int, int) void
Clip the expected and actual strings in a coordinated fashion, so that they may be displayed together.
static
ClipString(string, int, int) string
Clip a string to a given length, starting at a particular offset, returning the clipped string with ellipses representing the removed parts
static
EscapeControlChars(string) string
Converts any control characters in a string to their escaped representation.
static
FindMismatchPosition(string, string, int, bool) int
Shows the position two strings start to differ. Comparison starts at the start index.
static
FormatCollection(IEnumerable, long, int) string
Formats text for a collection value, starting at a particular point, to a max length
static
FormatValue(object) string
Formats text to represent a generalized value.
static
GetArrayIndicesAsString(int[]) string
Return the a string representation for a set of indices into an array
static
GetArrayIndicesFromCollectionIndex(IEnumerable, int) int[]
Get an array of indices representing the point in a enumerable, collection or array corresponding to a single int index into the collection.
static
GetTypeRepresentation(object) string
Returns the representation of a type as used in NUnitLite. This is the same as Type.ToString() except for arrays, which are displayed with their declared sizes.
static