mirror of
https://github.com/ManyakRus/starter.git
synced 2025-11-26 23:10:42 +02:00
сделал StringSplitBylength_WithLastWord()
This commit is contained in:
@@ -1543,3 +1543,11 @@ func TestStringSplitBylength(t *testing.T) {
|
||||
t.Errorf("Expected 'Приве', but got %s", MassOtvet[0])
|
||||
}
|
||||
}
|
||||
|
||||
func TestStringSplitBylength_WithLastWord(t *testing.T) {
|
||||
Text1 := "Привет мир"
|
||||
MassOtvet := StringSplitBylength_WithLastWord(Text1, 5, ' ')
|
||||
if MassOtvet[0] != "Приве" {
|
||||
t.Errorf("Expected 'Приве', but got %s", MassOtvet[0])
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user