附近小店
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

toke_test.go 581 B

2 달 전
1234567891011121314151617181920212223242526272829303132333435
  1. package test
  2. import (
  3. "applet/app/db"
  4. "applet/app/lib/taoke"
  5. "applet/app/svc"
  6. "fmt"
  7. "testing"
  8. )
  9. func TestBrandList(t *testing.T) {
  10. tkBrandStruct, err := taoke.BrandList("1", "20")
  11. if err != nil {
  12. t.Error(err)
  13. }
  14. for _, brandStruct := range *tkBrandStruct {
  15. fmt.Println(brandStruct)
  16. }
  17. }
  18. func TestSuperCategory(t *testing.T) {
  19. category, err := taoke.SuperCategory()
  20. if err != nil {
  21. t.Error(err)
  22. }
  23. for _, brandStruct := range *category {
  24. fmt.Println(brandStruct)
  25. }
  26. }
  27. func TestAddBrandDB(t *testing.T) {
  28. engine := db.DBs["123456"]
  29. svc.AddBrandDB(engine)
  30. }