/// <summary> /// Usefull to easily refactor old test code to new fluent api test code. Use this method, inline it (but keep its defintion), and polish /// </summary> internal static void TestStream(FragmentVerification fragment, Constraint dataFormat, Constraint length, Constraint isFragmented, Constraint fragmentedContrainer, Constraint fragmentedIndex, Constraint headerCount) { fragment.VerifyResultNode().HeaderCount(headerCount); fragment.DataFormat(dataFormat).Length(length).Fragmented(isFragmented).Container(fragmentedContrainer).Index(fragmentedIndex); }
/// <summary> /// Usefull to easily refactor old test code to new fluent api test code. Use this method, inline it (but keep its defintion), and polish /// </summary> internal static void TestOneHeader(FragmentVerification fragment, Constraint name, Constraint offset, Constraint length) { var result = fragment.VerifyResultNode().HeaderCountEquals(1).VerifyChild(0); result.Name(name).StartOffset(offset).Length(length); }
/// <summary> /// Usefull to easily refactor old test code to new fluent api test code. Use this method, inline it (but keep its defintion), and polish /// </summary> internal static void TestLastHeader(FragmentVerification fragment, Constraint name, Constraint offset, Constraint length) { var result = fragment.VerifyResultNode().Last(); result.Name(name).StartOffset(offset).Length(length); }