Documentation
¶
Index ¶
- Constants
- func AssertAdhanFileTimestampsCurrent(t *testing.T, a *pb.AdhanFile)
- func AssertEventTimestampsCurrent(t *testing.T, e *pb.Event)
- func AssertMasjidTimestampsCurrent(t *testing.T, m *pb.Masjid)
- func AssertProtoEqual(t *testing.T, expected, actual, typ interface{}, ignore cmp.Option)
- func AssertUserTimestampsCurrent(t *testing.T, u *pb.User)
- func GetAdhanFileProto() *pb.AdhanFile
- func GetEventProto() *pb.Event
- func GetMasjidProto() *pb.Masjid
- func GetNikkahLikeProto() *pb.NikkahLike
- func GetNikkahMatchProto() *pb.NikkahMatch
- func GetNikkahProfileProto() *pb.NikkahProfile
- func GetRevertMatchProto() *pb.RevertMatch
- func GetRevertProfileProto() *pb.RevertProfile
- func GetUserProto(email string, username string) *pb.User
- type IntegrationTestSuite
- type Resource
- type UnitTestSuite
Constants ¶
const ( DefaultId = "00000000-0000-0000-0000-000000000000" UserEmail = "[email protected]" Password = "password" BadPassword = "passwor" Username = "coolguy1234" FirstName = "John" LastName = "Doe" PhoneNumber = "+1234567890" MasjidName = "Masjid 1" EventName = "Event 1" EventDescription = "Some Event" LivestreamLink = "http://example.com" )
Variables ¶
This section is empty.
Functions ¶
func AssertAdhanFileTimestampsCurrent ¶
AssertAdhanFileTimestampsCurrent asserts that the create and update timestamps of the event are current. By current, it means that the timestamps are within a range of 1 second from now).
func AssertEventTimestampsCurrent ¶
AssertEventTimestampsCurrent asserts that the create and update timestamps of the event are current. By current, it means that the timestamps are within a range of 1 second from now).
func AssertMasjidTimestampsCurrent ¶
AssertMasjidTimestampsCurrent asserts that the create and update timestamps of the masjid are current. By current, it means that the timestamps are within a range of 1 second from now).
func AssertProtoEqual ¶
AssertProtoEqual asserts that two protobufs are equal, ignoring the fields specified in `ignoreFields`. An empty proto needs to be passed in as the `typ` argument.
func AssertUserTimestampsCurrent ¶
AssertUserTimestampsCurrent asserts that the create and update timestamps of the user are current. By current, it means that the timestamps are within a range of 1 second from now).
func GetAdhanFileProto ¶
func GetEventProto ¶
func GetMasjidProto ¶
func GetNikkahLikeProto ¶
func GetNikkahLikeProto() *pb.NikkahLike
func GetNikkahMatchProto ¶
func GetNikkahMatchProto() *pb.NikkahMatch
func GetNikkahProfileProto ¶
func GetNikkahProfileProto() *pb.NikkahProfile
func GetRevertMatchProto ¶
func GetRevertMatchProto() *pb.RevertMatch
func GetRevertProfileProto ¶
func GetRevertProfileProto() *pb.RevertProfile
Types ¶
type IntegrationTestSuite ¶
type IntegrationTestSuite struct { suite.Suite DB *gorm.DB Server *grpc.Server AdhanServiceClient pb.AdhanServiceClient EventServiceClient pb.EventServiceClient MasjidServiceClient pb.MasjidServiceClient UserServiceClient pb.UserServiceClient }
func (*IntegrationTestSuite) AfterTest ¶
func (suite *IntegrationTestSuite) AfterTest(suiteName, testName string)
func (*IntegrationTestSuite) BeforeTest ¶
func (suite *IntegrationTestSuite) BeforeTest(suiteName, testName string)
type Resource ¶
type Resource struct { CreateTime *timestamppb.Timestamp UpdateTime *timestamppb.Timestamp }
type UnitTestSuite ¶
type UnitTestSuite struct { suite.Suite StorageManager *storage.StorageManager }
func (*UnitTestSuite) BeforeTest ¶
func (suite *UnitTestSuite) BeforeTest(suiteName, testName string)