Skip to content

StringAssertions.HaveLength Method

Definition

Asserts that the string has the specified length.

public StringAssertionsChain HaveLength(int expected);

Parameters

Name Type Description
expected Int32 The expected length.

Returns

StringAssertionsChain

A StringAssertionsChain for chaining further assertions.