text table, telegram html message
This commit is contained in:
20
tools_test.go
Normal file
20
tools_test.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package notify_test
|
||||
|
||||
import (
|
||||
"log"
|
||||
"testing"
|
||||
|
||||
"git.gm6.ru/icewind/notify"
|
||||
)
|
||||
|
||||
func TestCreateTable(t *testing.T) {
|
||||
rows := [][]string{
|
||||
{"Название", "Цена", "Кол-во", "Рост"},
|
||||
{"Яблоки", "120", "5", "3.5"},
|
||||
{"Бананы", "-90", "30", "12 000"},
|
||||
{"Киви", "+200", "1", "-1.2"},
|
||||
}
|
||||
|
||||
msg := notify.BuildTelegramHTMLTable(rows)
|
||||
log.Println(msg)
|
||||
}
|
||||
Reference in New Issue
Block a user