golang-im聊天
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

24 lines
426 B

  1. package friend
  2. import (
  3. "fmt"
  4. "testing"
  5. )
  6. func Test_friendDao_Get(t *testing.T) {
  7. friend, err := FriendRepo.Get(1, 2)
  8. fmt.Printf("%+v \n %+v \n", friend, err)
  9. }
  10. func Test_friendDao_Save(t *testing.T) {
  11. fmt.Println(FriendRepo.Save(&Friend{
  12. UserId: 1,
  13. FriendId: 2,
  14. }))
  15. }
  16. func Test_friendDao_List(t *testing.T) {
  17. friends, err := FriendRepo.List(1, FriendStatusAgree)
  18. fmt.Printf("%+v \n %+v \n", friends, err)
  19. }