1
0
mirror of https://github.com/ManyakRus/crud_generator.git synced 2025-05-21 10:53:11 +02:00

25 lines
533 B
Go
Raw Normal View History

2023-09-28 17:45:44 +03:00
package postgres
import (
2024-05-29 14:18:58 +03:00
"github.com/ManyakRus/crud_generator/internal/config"
2024-10-14 16:13:02 +03:00
"github.com/ManyakRus/crud_generator/internal/database"
2023-09-28 17:45:44 +03:00
"github.com/ManyakRus/starter/postgres_gorm"
"testing"
)
func TestFillMassTable(t *testing.T) {
2024-05-29 14:18:58 +03:00
//ConfigMain.LoadEnv()
config.LoadSettingsTxt()
2023-09-28 17:45:44 +03:00
postgres_gorm.Connect()
defer postgres_gorm.CloseConnection()
2024-10-14 16:13:02 +03:00
Otvet, err := database.FillMapTable()
2023-09-28 17:45:44 +03:00
if err != nil {
t.Error("TestFillMassTable() error: ", err)
}
if len(Otvet) == 0 {
t.Error("TestFillMassTable() error: len =0")
}
}