Skip to content

Commit 2ada6f7

Browse files
committed
this can generate illegal chars so I've changed over to just shorten the standard Create returned string to the required length.
1 parent 8abdb7f commit 2ada6f7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

FluentCommandLineParser.Tests/Internals/TestContextBase.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ protected static List<TType> CreateManyAsList<TType>(params TType[] additionalIt
118118

119119
protected static string CreateStringOfLength(int length)
120120
{
121-
return new string(Create<char>(), length);
121+
var str = Create<string>();
122+
return new string(str.Take(length).ToArray());
122123
}
123124
}
124125
}

0 commit comments

Comments
 (0)