1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3// Package amplifyiface provides an interface to enable mocking the AWS Amplify service client 4// for testing your code. 5// 6// It is important to note that this interface will have breaking changes 7// when the service model is updated and adds new API operations, paginators, 8// and waiters. 9package amplifyiface 10 11import ( 12 "github.com/aws/aws-sdk-go/aws" 13 "github.com/aws/aws-sdk-go/aws/request" 14 "github.com/aws/aws-sdk-go/service/amplify" 15) 16 17// AmplifyAPI provides an interface to enable mocking the 18// amplify.Amplify service client's API operation, 19// paginators, and waiters. This make unit testing your code that calls out 20// to the SDK's service client's calls easier. 21// 22// The best way to use this interface is so the SDK's service client's calls 23// can be stubbed out for unit testing your code with the SDK without needing 24// to inject custom request handlers into the SDK's request pipeline. 25// 26// // myFunc uses an SDK service client to make a request to 27// // AWS Amplify. 28// func myFunc(svc amplifyiface.AmplifyAPI) bool { 29// // Make svc.CreateApp request 30// } 31// 32// func main() { 33// sess := session.New() 34// svc := amplify.New(sess) 35// 36// myFunc(svc) 37// } 38// 39// In your _test.go file: 40// 41// // Define a mock struct to be used in your unit tests of myFunc. 42// type mockAmplifyClient struct { 43// amplifyiface.AmplifyAPI 44// } 45// func (m *mockAmplifyClient) CreateApp(input *amplify.CreateAppInput) (*amplify.CreateAppOutput, error) { 46// // mock response/functionality 47// } 48// 49// func TestMyFunc(t *testing.T) { 50// // Setup Test 51// mockSvc := &mockAmplifyClient{} 52// 53// myfunc(mockSvc) 54// 55// // Verify myFunc's functionality 56// } 57// 58// It is important to note that this interface will have breaking changes 59// when the service model is updated and adds new API operations, paginators, 60// and waiters. Its suggested to use the pattern above for testing, or using 61// tooling to generate mocks to satisfy the interfaces. 62type AmplifyAPI interface { 63 CreateApp(*amplify.CreateAppInput) (*amplify.CreateAppOutput, error) 64 CreateAppWithContext(aws.Context, *amplify.CreateAppInput, ...request.Option) (*amplify.CreateAppOutput, error) 65 CreateAppRequest(*amplify.CreateAppInput) (*request.Request, *amplify.CreateAppOutput) 66 67 CreateBranch(*amplify.CreateBranchInput) (*amplify.CreateBranchOutput, error) 68 CreateBranchWithContext(aws.Context, *amplify.CreateBranchInput, ...request.Option) (*amplify.CreateBranchOutput, error) 69 CreateBranchRequest(*amplify.CreateBranchInput) (*request.Request, *amplify.CreateBranchOutput) 70 71 CreateDeployment(*amplify.CreateDeploymentInput) (*amplify.CreateDeploymentOutput, error) 72 CreateDeploymentWithContext(aws.Context, *amplify.CreateDeploymentInput, ...request.Option) (*amplify.CreateDeploymentOutput, error) 73 CreateDeploymentRequest(*amplify.CreateDeploymentInput) (*request.Request, *amplify.CreateDeploymentOutput) 74 75 CreateDomainAssociation(*amplify.CreateDomainAssociationInput) (*amplify.CreateDomainAssociationOutput, error) 76 CreateDomainAssociationWithContext(aws.Context, *amplify.CreateDomainAssociationInput, ...request.Option) (*amplify.CreateDomainAssociationOutput, error) 77 CreateDomainAssociationRequest(*amplify.CreateDomainAssociationInput) (*request.Request, *amplify.CreateDomainAssociationOutput) 78 79 CreateWebhook(*amplify.CreateWebhookInput) (*amplify.CreateWebhookOutput, error) 80 CreateWebhookWithContext(aws.Context, *amplify.CreateWebhookInput, ...request.Option) (*amplify.CreateWebhookOutput, error) 81 CreateWebhookRequest(*amplify.CreateWebhookInput) (*request.Request, *amplify.CreateWebhookOutput) 82 83 DeleteApp(*amplify.DeleteAppInput) (*amplify.DeleteAppOutput, error) 84 DeleteAppWithContext(aws.Context, *amplify.DeleteAppInput, ...request.Option) (*amplify.DeleteAppOutput, error) 85 DeleteAppRequest(*amplify.DeleteAppInput) (*request.Request, *amplify.DeleteAppOutput) 86 87 DeleteBranch(*amplify.DeleteBranchInput) (*amplify.DeleteBranchOutput, error) 88 DeleteBranchWithContext(aws.Context, *amplify.DeleteBranchInput, ...request.Option) (*amplify.DeleteBranchOutput, error) 89 DeleteBranchRequest(*amplify.DeleteBranchInput) (*request.Request, *amplify.DeleteBranchOutput) 90 91 DeleteDomainAssociation(*amplify.DeleteDomainAssociationInput) (*amplify.DeleteDomainAssociationOutput, error) 92 DeleteDomainAssociationWithContext(aws.Context, *amplify.DeleteDomainAssociationInput, ...request.Option) (*amplify.DeleteDomainAssociationOutput, error) 93 DeleteDomainAssociationRequest(*amplify.DeleteDomainAssociationInput) (*request.Request, *amplify.DeleteDomainAssociationOutput) 94 95 DeleteJob(*amplify.DeleteJobInput) (*amplify.DeleteJobOutput, error) 96 DeleteJobWithContext(aws.Context, *amplify.DeleteJobInput, ...request.Option) (*amplify.DeleteJobOutput, error) 97 DeleteJobRequest(*amplify.DeleteJobInput) (*request.Request, *amplify.DeleteJobOutput) 98 99 DeleteWebhook(*amplify.DeleteWebhookInput) (*amplify.DeleteWebhookOutput, error) 100 DeleteWebhookWithContext(aws.Context, *amplify.DeleteWebhookInput, ...request.Option) (*amplify.DeleteWebhookOutput, error) 101 DeleteWebhookRequest(*amplify.DeleteWebhookInput) (*request.Request, *amplify.DeleteWebhookOutput) 102 103 GetApp(*amplify.GetAppInput) (*amplify.GetAppOutput, error) 104 GetAppWithContext(aws.Context, *amplify.GetAppInput, ...request.Option) (*amplify.GetAppOutput, error) 105 GetAppRequest(*amplify.GetAppInput) (*request.Request, *amplify.GetAppOutput) 106 107 GetBranch(*amplify.GetBranchInput) (*amplify.GetBranchOutput, error) 108 GetBranchWithContext(aws.Context, *amplify.GetBranchInput, ...request.Option) (*amplify.GetBranchOutput, error) 109 GetBranchRequest(*amplify.GetBranchInput) (*request.Request, *amplify.GetBranchOutput) 110 111 GetDomainAssociation(*amplify.GetDomainAssociationInput) (*amplify.GetDomainAssociationOutput, error) 112 GetDomainAssociationWithContext(aws.Context, *amplify.GetDomainAssociationInput, ...request.Option) (*amplify.GetDomainAssociationOutput, error) 113 GetDomainAssociationRequest(*amplify.GetDomainAssociationInput) (*request.Request, *amplify.GetDomainAssociationOutput) 114 115 GetJob(*amplify.GetJobInput) (*amplify.GetJobOutput, error) 116 GetJobWithContext(aws.Context, *amplify.GetJobInput, ...request.Option) (*amplify.GetJobOutput, error) 117 GetJobRequest(*amplify.GetJobInput) (*request.Request, *amplify.GetJobOutput) 118 119 GetWebhook(*amplify.GetWebhookInput) (*amplify.GetWebhookOutput, error) 120 GetWebhookWithContext(aws.Context, *amplify.GetWebhookInput, ...request.Option) (*amplify.GetWebhookOutput, error) 121 GetWebhookRequest(*amplify.GetWebhookInput) (*request.Request, *amplify.GetWebhookOutput) 122 123 ListApps(*amplify.ListAppsInput) (*amplify.ListAppsOutput, error) 124 ListAppsWithContext(aws.Context, *amplify.ListAppsInput, ...request.Option) (*amplify.ListAppsOutput, error) 125 ListAppsRequest(*amplify.ListAppsInput) (*request.Request, *amplify.ListAppsOutput) 126 127 ListBranches(*amplify.ListBranchesInput) (*amplify.ListBranchesOutput, error) 128 ListBranchesWithContext(aws.Context, *amplify.ListBranchesInput, ...request.Option) (*amplify.ListBranchesOutput, error) 129 ListBranchesRequest(*amplify.ListBranchesInput) (*request.Request, *amplify.ListBranchesOutput) 130 131 ListDomainAssociations(*amplify.ListDomainAssociationsInput) (*amplify.ListDomainAssociationsOutput, error) 132 ListDomainAssociationsWithContext(aws.Context, *amplify.ListDomainAssociationsInput, ...request.Option) (*amplify.ListDomainAssociationsOutput, error) 133 ListDomainAssociationsRequest(*amplify.ListDomainAssociationsInput) (*request.Request, *amplify.ListDomainAssociationsOutput) 134 135 ListJobs(*amplify.ListJobsInput) (*amplify.ListJobsOutput, error) 136 ListJobsWithContext(aws.Context, *amplify.ListJobsInput, ...request.Option) (*amplify.ListJobsOutput, error) 137 ListJobsRequest(*amplify.ListJobsInput) (*request.Request, *amplify.ListJobsOutput) 138 139 ListTagsForResource(*amplify.ListTagsForResourceInput) (*amplify.ListTagsForResourceOutput, error) 140 ListTagsForResourceWithContext(aws.Context, *amplify.ListTagsForResourceInput, ...request.Option) (*amplify.ListTagsForResourceOutput, error) 141 ListTagsForResourceRequest(*amplify.ListTagsForResourceInput) (*request.Request, *amplify.ListTagsForResourceOutput) 142 143 ListWebhooks(*amplify.ListWebhooksInput) (*amplify.ListWebhooksOutput, error) 144 ListWebhooksWithContext(aws.Context, *amplify.ListWebhooksInput, ...request.Option) (*amplify.ListWebhooksOutput, error) 145 ListWebhooksRequest(*amplify.ListWebhooksInput) (*request.Request, *amplify.ListWebhooksOutput) 146 147 StartDeployment(*amplify.StartDeploymentInput) (*amplify.StartDeploymentOutput, error) 148 StartDeploymentWithContext(aws.Context, *amplify.StartDeploymentInput, ...request.Option) (*amplify.StartDeploymentOutput, error) 149 StartDeploymentRequest(*amplify.StartDeploymentInput) (*request.Request, *amplify.StartDeploymentOutput) 150 151 StartJob(*amplify.StartJobInput) (*amplify.StartJobOutput, error) 152 StartJobWithContext(aws.Context, *amplify.StartJobInput, ...request.Option) (*amplify.StartJobOutput, error) 153 StartJobRequest(*amplify.StartJobInput) (*request.Request, *amplify.StartJobOutput) 154 155 StopJob(*amplify.StopJobInput) (*amplify.StopJobOutput, error) 156 StopJobWithContext(aws.Context, *amplify.StopJobInput, ...request.Option) (*amplify.StopJobOutput, error) 157 StopJobRequest(*amplify.StopJobInput) (*request.Request, *amplify.StopJobOutput) 158 159 TagResource(*amplify.TagResourceInput) (*amplify.TagResourceOutput, error) 160 TagResourceWithContext(aws.Context, *amplify.TagResourceInput, ...request.Option) (*amplify.TagResourceOutput, error) 161 TagResourceRequest(*amplify.TagResourceInput) (*request.Request, *amplify.TagResourceOutput) 162 163 UntagResource(*amplify.UntagResourceInput) (*amplify.UntagResourceOutput, error) 164 UntagResourceWithContext(aws.Context, *amplify.UntagResourceInput, ...request.Option) (*amplify.UntagResourceOutput, error) 165 UntagResourceRequest(*amplify.UntagResourceInput) (*request.Request, *amplify.UntagResourceOutput) 166 167 UpdateApp(*amplify.UpdateAppInput) (*amplify.UpdateAppOutput, error) 168 UpdateAppWithContext(aws.Context, *amplify.UpdateAppInput, ...request.Option) (*amplify.UpdateAppOutput, error) 169 UpdateAppRequest(*amplify.UpdateAppInput) (*request.Request, *amplify.UpdateAppOutput) 170 171 UpdateBranch(*amplify.UpdateBranchInput) (*amplify.UpdateBranchOutput, error) 172 UpdateBranchWithContext(aws.Context, *amplify.UpdateBranchInput, ...request.Option) (*amplify.UpdateBranchOutput, error) 173 UpdateBranchRequest(*amplify.UpdateBranchInput) (*request.Request, *amplify.UpdateBranchOutput) 174 175 UpdateDomainAssociation(*amplify.UpdateDomainAssociationInput) (*amplify.UpdateDomainAssociationOutput, error) 176 UpdateDomainAssociationWithContext(aws.Context, *amplify.UpdateDomainAssociationInput, ...request.Option) (*amplify.UpdateDomainAssociationOutput, error) 177 UpdateDomainAssociationRequest(*amplify.UpdateDomainAssociationInput) (*request.Request, *amplify.UpdateDomainAssociationOutput) 178 179 UpdateWebhook(*amplify.UpdateWebhookInput) (*amplify.UpdateWebhookOutput, error) 180 UpdateWebhookWithContext(aws.Context, *amplify.UpdateWebhookInput, ...request.Option) (*amplify.UpdateWebhookOutput, error) 181 UpdateWebhookRequest(*amplify.UpdateWebhookInput) (*request.Request, *amplify.UpdateWebhookOutput) 182} 183 184var _ AmplifyAPI = (*amplify.Amplify)(nil) 185