@@ -78,37 +78,6 @@ public void AbsolutizeShouldThrowExceptionIfStringIsNull()
78
78
Assert . Equal ( "Cannot absolutize a null path" , message ) ;
79
79
}
80
80
81
- [ Theory ]
82
- [ InlineData ( "test string" , 0 , "test string" ) ]
83
- [ InlineData ( "test string" , 2 , "st string" ) ]
84
- public void ShouldSliceStringWithStart ( string value , int start , string expected )
85
- {
86
- Assert . Equal ( expected , value . Slice ( start ) ) ;
87
- }
88
-
89
- [ Theory ]
90
- [ InlineData ( "test string" , 2 , 7 , "st st" ) ]
91
- [ InlineData ( "test string" , 2 , - 2 , "st stri" ) ]
92
- public void ShouldSliceString ( string value , int start , int end , string expected )
93
- {
94
- Assert . Equal ( expected , value . Slice ( start , end ) ) ;
95
- }
96
-
97
- [ Fact ]
98
- public void SliceShouldThrowExceptionIfStringIsNull ( )
99
- {
100
- string test = default ;
101
- var message = Assert . Throws < ArgumentException > ( ( ) => test . Slice ( 2 , 5 ) ) . Message ;
102
- Assert . Equal ( "Cannot slice a null string" , message ) ;
103
- }
104
-
105
- [ Fact ]
106
- public void SliceShouldThrowExceptionIfStartIsNegative ( )
107
- {
108
- var message = Assert . Throws < ArgumentException > ( ( ) => "test string" . Slice ( - 1 , 5 ) ) . Message ;
109
- Assert . Equal ( "Slice cannot have a negative start" , message ) ;
110
- }
111
-
112
81
[ Theory ]
113
82
[ InlineData ( "ThisIsATestString" , "This Is A Test String" ) ]
114
83
[ InlineData ( "_ThisIsATestString" , "This Is A Test String" ) ]
@@ -249,16 +218,6 @@ public void ShouldRemoveDiacritics(string input, string expected)
249
218
Assert . Equal ( expected , input . RemoveDiacritics ( ) ) ;
250
219
}
251
220
252
- [ Theory ]
253
- [ InlineData ( default , default ) ]
254
- [ InlineData ( "test" , "test" ) ]
255
- [ InlineData ( "TEST" , "tEST" ) ]
256
- [ InlineData ( "Test" , "test" ) ]
257
- public void ShouldLowerFirstLetter ( string input , string expected )
258
- {
259
- Assert . Equal ( expected , input . LowerFirstLetter ( ) ) ;
260
- }
261
-
262
221
[ Theory ]
263
222
[ InlineData ( default , 0 ) ]
264
223
[ InlineData ( "42" , 42 ) ]
@@ -275,5 +234,17 @@ public void ShouldRemoveCharFromString(string text1, string text2, string expect
275
234
{
276
235
Assert . Equal ( expected , text1 . Except ( text2 ) ) ;
277
236
}
237
+
238
+ [ Theory ]
239
+ [ InlineData ( "Test" , "test" ) ]
240
+ [ InlineData ( "TEST" , "tEST" ) ]
241
+ [ InlineData ( "T" , "t" ) ]
242
+ [ InlineData ( "t" , "t" ) ]
243
+ [ InlineData ( "" , "" ) ]
244
+ [ InlineData ( default , default ) ]
245
+ public void ShouldLowerFirstChar ( string str , string expected )
246
+ {
247
+ Assert . Equal ( expected , str . LowerFirstLetter ( ) ) ;
248
+ }
278
249
}
279
250
}
0 commit comments