File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
src/libraries/System.Runtime.Numerics/tests/BigInteger Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -154,6 +154,33 @@ public void Parse_Hex32Bits()
154154 } ) ;
155155 }
156156
157+ public static IEnumerable < object [ ] > RegressionIssueRuntime94610_TestData ( )
158+ {
159+ yield return new object [ ]
160+ {
161+ new string ( '9' , 865 ) ,
162+ } ;
163+
164+ yield return new object [ ]
165+ {
166+ new string ( '9' , 20161 ) ,
167+ } ;
168+ }
169+
170+ [ Theory ]
171+ [ MemberData ( nameof ( RegressionIssueRuntime94610_TestData ) ) ]
172+ public void RegressionIssueRuntime94610 ( string text )
173+ {
174+ // Regression test for: https://github.com/dotnet/runtime/issues/94610
175+ Test ( ) ;
176+ BigIntTools . Utils . RunWithFakeThreshold ( Number . s_naiveThreshold , 0 , Test ) ;
177+
178+ void Test ( )
179+ {
180+ VerifyParseToString ( text , NumberStyles . Integer , true ) ;
181+ }
182+ }
183+
157184 private static void RunFormatProviderParseStrings ( )
158185 {
159186 NumberFormatInfo nfi = new NumberFormatInfo ( ) ;
You can’t perform that action at this time.
0 commit comments