Documentation ¶
Overview ¶
Package topic provides functions and filters to test AWS SNS Topics
Index ¶
- type Attributes
- type Topic
- func (r *Topic) Arn(arn string) *Topic
- func (r *Topic) Assert(t *testing.T, topics ...*Attributes) *Topic
- func (r *Topic) DisplayName(name string) *Topic
- func (r *Topic) Filter(filter shared.Filter) *Topic
- func (r *Topic) First(t *testing.T, topics ...*Attributes) *Topic
- func (r *Topic) KmsMasterKeyID(id string) *Topic
- func (r *Topic) Name(name string) *Topic
- func (r *Topic) Owner(str string) *Topic
- func (r *Topic) Policy() *policy.Policy
- func (r *Topic) Selected() *Attributes
- func (r *Topic) TopicArn(arn string) *Topic
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attributes ¶
type Attributes struct { Policy string DeliveryPolicy string Owner string SubscriptionsPending string TopicArn string EffectiveDeliveryPolicy string SubscriptionsConfirmed string DisplayName string SubscriptionsDeleted string KmsMasterKeyID string `json:"KmsMasterKeyId"` }
Attributes A struct of the topic's attributes map.
type Topic ¶
type Topic struct {
// contains filtered or unexported fields
}
Topic contains the necessary properties for testing *sns.Topic objects
func (*Topic) Assert ¶
func (r *Topic) Assert(t *testing.T, topics ...*Attributes) *Topic
Assert applies all filters that have been called, resets the list of filters, fails the test if there is not exactly one match, and stores the matched topic if topics is not provided, *Attributes objects will be retreived from AWS
func (*Topic) DisplayName ¶
DisplayName adds the DisplayName filter to the filter list the DisplayName filter: filters topics by DisplayName where 'name' provided is the expected DisplayName value
func (*Topic) First ¶
func (r *Topic) First(t *testing.T, topics ...*Attributes) *Topic
First applies all filters that have been called, resets the list of filters, fails the test if there are no matches, and stores the first match if topics is not provided, *Attributes objects will be retreived from AWS
func (*Topic) KmsMasterKeyID ¶
KmsMasterKeyID adds the KmsMasterKeyID filter to the filter list the KmsMasterKeyID filter: filters topics by KmsMasterKeyId where 'id' provided is the expected KmsMasterKeyId value
func (*Topic) Owner ¶
Owner adds the Owner filter to the filter list the Owner filter: filters topics by Owner where 'str' provided is the expected Owner value
func (*Topic) Policy ¶
Policy returns a new *policy.Policy instantiated with the current bucket name set by calling Name()
func (*Topic) Selected ¶
func (r *Topic) Selected() *Attributes
Selected returns the currently selected *Attributes