1
0
mirror of https://github.com/ManyakRus/starter.git synced 2025-11-26 23:10:42 +02:00

сделал stringSplitBylength_WithLastWord1()

This commit is contained in:
Nikitin Aleksandr
2025-06-09 17:05:41 +03:00
parent 3bb017824e
commit 0ece489c19
2 changed files with 22 additions and 0 deletions

View File

@@ -1552,6 +1552,14 @@ func TestStringSplitBylength_WithLastWord(t *testing.T) {
}
}
func TestStringSplitBylength_WithLastWord2(t *testing.T) {
Text1 := "Покупка RU000A10A9Z1 (https://www.tbank.ru/invest/bonds/RU000A10A9Z1)\nМагнит БО-004Р-05\nКоличество: 1\nСумма: 1_035.10 руб.\nЦена: 103.51% = 1_035.10 руб.\nПроцент годовых: 23.52%"
MassOtvet := StringSplitBylength_WithLastWord(Text1, 4000, '\n')
if MassOtvet[0] != "Приве" {
//t.Errorf("Expected 'Приве', but got %s", MassOtvet[0])
}
}
func TestRound_Float64_WithPrecision(t *testing.T) {
Otvet := Round_Float64_WithPrecision(1.11, 1)
if Otvet != 1.1 {