//---------------------------------------------------------------------------
// Wrapper for TextPatternRange.Move Method
//---------------------------------------------------------------------------
internal void Range_Move(TextPatternRange callingRange, TextUnit unit, int moveCount, ref int actualCount, Type expectedException, CheckType checkType)
{
string call = "TextPatternRange.Move(" + unit + ", " + moveCount + ")";
if (callingRange == null)
throw new ArgumentNullException(call + " requires non-NULL TextPatterncallingRange");
try
{
actualCount = callingRange.Move(unit, moveCount);
Comment("---Called " + call + ", returned = " + actualCount);
}
catch (Exception actualException)
{
if (Library.IsCriticalException(actualException))
throw;
Comment("---Calling " + call); // we don't have a count, but still tell user we called
TestException(expectedException, actualException, call, checkType);
return;
}
TestNoExceptionQuiet(expectedException, call, checkType);
}