StringAssertions.HaveLength Method
Definition
Asserts that the string has the specified length.
c#
public AssertionsChain<StringAssertions, string> HaveLength(int expected);Parameters
| Name | Type | Description |
|---|---|---|
expected | Int32 | The expected length. |
Returns
AssertionsChain<StringAssertions, String>
An AssertionsChain<TAssertions, T> for chaining further assertions.