tests

package
v0.0.0-...-48bfdbc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: MIT Imports: 23 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AccessToken

func AccessToken(db *gorm.DB) string

func AnotherAccessToken

func AnotherAccessToken(db *gorm.DB) string

func CloseTestDatabase

func CloseTestDatabase(db *gorm.DB)

func ConvertDateTime

func ConvertDateTime(timeObj time.Time) string

func CreateAnotherTestVerifiedUser

func CreateAnotherTestVerifiedUser(db *gorm.DB) models.User

func CreateChat

func CreateChat(db *gorm.DB) models.Chat

CHAT FIXTURES

func CreateCity

func CreateCity(db *gorm.DB) models.City

PROFILE FIXTURES

func CreateComment

func CreateComment(db *gorm.DB) models.Comment

func CreateFriend

func CreateFriend(db *gorm.DB, status choices.FriendStatusChoice) models.Friend

func CreateGroupChat

func CreateGroupChat(db *gorm.DB) models.Chat

func CreateJwt

func CreateJwt(db *gorm.DB, user models.User) models.User

func CreateMessage

func CreateMessage(db *gorm.DB) models.Message

func CreateNotification

func CreateNotification(db *gorm.DB) models.Notification

func CreatePost

func CreatePost(db *gorm.DB) models.Post

FEED FIXTURES

func CreateReaction

func CreateReaction(db *gorm.DB) models.Reaction

func CreateReply

func CreateReply(db *gorm.DB) models.Reply

func CreateSingleTable

func CreateSingleTable(db *gorm.DB, model interface{})

func CreateTestUser

func CreateTestUser(db *gorm.DB) models.User

AUTH FIXTURES

func CreateTestVerifiedUser

func CreateTestVerifiedUser(db *gorm.DB) models.User

func DropAndCreateSingleTable

func DropAndCreateSingleTable(db *gorm.DB, model interface{})

func GetUserMap

func GetUserMap(user models.User) map[string]interface{}

Utils

func ParseResponseBody

func ParseResponseBody(t *testing.T, b io.ReadCloser) interface{}

func ProcessTestBody

func ProcessTestBody(t *testing.T, app *fiber.App, url string, method string, body interface{}, access ...string) *http.Response

func RemoveCreatedAndUpdated

func RemoveCreatedAndUpdated(body map[string]interface{}, dataType string)

func Setup

func Setup(t *testing.T, app *fiber.App) *gorm.DB

func SetupTestDatabase

func SetupTestDatabase(t *testing.T) *gorm.DB

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL