// Code generated by smithy-go-codegen DO NOT EDIT.

//go:build response_snapshot

package codeartifact

import (
	"bufio"
	"bytes"
	"context"
	"errors"
	"fmt"
	"github.com/aws/aws-sdk-go-v2/service/codeartifact/types"
	smithyendpoints "github.com/aws/smithy-go/endpoints"
	"github.com/aws/smithy-go/middleware"
	"github.com/aws/smithy-go/ptr"
	smithytesting "github.com/aws/smithy-go/testing"
	smithyhttp "github.com/aws/smithy-go/transport/http"
	"io"
	"io/fs"
	"net/http"
	"net/url"
	"os"
	"strconv"
	"strings"
	"testing"
	"time"
)

const serdeRespSSPrefix = "response_snapshot"

func serdeRespSSPath(op string) string {
	return fmt.Sprintf("%s/%s.snap", serdeRespSSPrefix, op)
}

// serdeRespReadSnapshot parses a frozen wire response fixture: a status-code
// line, HTTP headers, a blank line, then the raw body.
func serdeRespReadSnapshot(op string) (int, http.Header, []byte, error) {
	raw, err := os.ReadFile(serdeRespSSPath(op))
	if err != nil {
		return 0, nil, nil, err
	}

	r := bufio.NewReader(bytes.NewReader(raw))
	statusLine, err := r.ReadString('\n')
	if err != nil {
		return 0, nil, nil, fmt.Errorf("read status line: %w", err)
	}
	status, err := strconv.Atoi(strings.TrimSpace(statusLine))
	if err != nil {
		return 0, nil, nil, fmt.Errorf("parse status: %w", err)
	}

	header := http.Header{}
	for {
		line, err := r.ReadString('\n')
		if err != nil && err != io.EOF {
			return 0, nil, nil, err
		}
		trimmed := strings.TrimRight(line, "\r\n")
		if trimmed == "" {
			break
		}
		k, v, ok := strings.Cut(trimmed, ": ")
		if !ok {
			return 0, nil, nil, fmt.Errorf("malformed header %q", trimmed)
		}
		header.Add(k, v)
		if err == io.EOF {
			break
		}
	}

	body, err := io.ReadAll(r)
	if err != nil {
		return 0, nil, nil, err
	}
	return status, header, body, nil
}

type serdeRespEndpointResolver struct{}

func (*serdeRespEndpointResolver) ResolveEndpoint(ctx context.Context, params EndpointParameters) (smithyendpoints.Endpoint, error) {
	return smithyendpoints.Endpoint{URI: url.URL{Scheme: "https", Host: "test.example.com"}}, nil
}

func serdeRespClient(status int, header http.Header, body []byte) *Client {
	return New(Options{
		Region: "us-east-1",
		HTTPClient: smithyhttp.ClientDoFunc(func(req *http.Request) (*http.Response, error) {
			resp := &http.Response{StatusCode: status, Header: header, Request: req}
			if len(body) > 0 {
				resp.ContentLength = int64(len(body))
				resp.Body = io.NopCloser(bytes.NewReader(body))
			} else {
				resp.Body = http.NoBody
			}
			return resp, nil
		}),
		EndpointResolverV2: &serdeRespEndpointResolver{},
		APIOptions: []func(*middleware.Stack) error{
			func(s *middleware.Stack) error {
				s.Finalize.Clear()
				s.Initialize.Remove("OperationInputValidation")
				return nil
			},
		},
	})
}
func TestCheckResponseSnapshot_AssociateExternalConnection(t *testing.T) {
	want := &AssociateExternalConnectionOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("AssociateExternalConnection.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "AssociateExternalConnection.response", err)
	}
}

func TestCheckResponseSnapshot_CopyPackageVersions(t *testing.T) {
	want := &CopyPackageVersionsOutput{
		SuccessfulVersions: map[string]types.SuccessfulPackageVersionInfo{
			"key0": {
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
			},
		},
		FailedVersions: map[string]types.PackageVersionError{
			"key0": {
				ErrorCode:    types.PackageVersionErrorCode("ALREADY_EXISTS"),
				ErrorMessage: ptr.String("__ErrorMessage__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("CopyPackageVersions.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.CopyPackageVersions(context.Background(), &CopyPackageVersionsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "CopyPackageVersions.response", err)
	}
}

func TestCheckResponseSnapshot_CreateDomain(t *testing.T) {
	want := &CreateDomainOutput{
		Domain: &types.DomainDescription{
			Name:            ptr.String("__Name__"),
			Owner:           ptr.String("__Owner__"),
			Arn:             ptr.String("__Arn__"),
			Status:          types.DomainStatus("Active"),
			CreatedTime:     ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			EncryptionKey:   ptr.String("__EncryptionKey__"),
			RepositoryCount: 1,
			AssetSizeBytes:  1,
			S3BucketArn:     ptr.String("__S3BucketArn__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("CreateDomain.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.CreateDomain(context.Background(), &CreateDomainInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "CreateDomain.response", err)
	}
}

func TestCheckResponseSnapshot_CreatePackageGroup(t *testing.T) {
	want := &CreatePackageGroupOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("CreatePackageGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.CreatePackageGroup(context.Background(), &CreatePackageGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "CreatePackageGroup.response", err)
	}
}

func TestCheckResponseSnapshot_CreateRepository(t *testing.T) {
	want := &CreateRepositoryOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("CreateRepository.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.CreateRepository(context.Background(), &CreateRepositoryInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "CreateRepository.response", err)
	}
}

func TestCheckResponseSnapshot_DeleteDomain(t *testing.T) {
	want := &DeleteDomainOutput{
		Domain: &types.DomainDescription{
			Name:            ptr.String("__Name__"),
			Owner:           ptr.String("__Owner__"),
			Arn:             ptr.String("__Arn__"),
			Status:          types.DomainStatus("Active"),
			CreatedTime:     ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			EncryptionKey:   ptr.String("__EncryptionKey__"),
			RepositoryCount: 1,
			AssetSizeBytes:  1,
			S3BucketArn:     ptr.String("__S3BucketArn__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeleteDomain.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeleteDomain(context.Background(), &DeleteDomainInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeleteDomain.response", err)
	}
}

func TestCheckResponseSnapshot_DeleteDomainPermissionsPolicy(t *testing.T) {
	want := &DeleteDomainPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeleteDomainPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeleteDomainPermissionsPolicy(context.Background(), &DeleteDomainPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeleteDomainPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_DeletePackage(t *testing.T) {
	want := &DeletePackageOutput{
		DeletedPackage: &types.PackageSummary{
			Format:    types.PackageFormat("npm"),
			Namespace: ptr.String("__Namespace__"),
			Package:   ptr.String("__Package__"),
			OriginConfiguration: &types.PackageOriginConfiguration{
				Restrictions: &types.PackageOriginRestrictions{
					Publish:  types.AllowPublish("ALLOW"),
					Upstream: types.AllowUpstream("ALLOW"),
				},
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeletePackage.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeletePackage(context.Background(), &DeletePackageInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeletePackage.response", err)
	}
}

func TestCheckResponseSnapshot_DeletePackageGroup(t *testing.T) {
	want := &DeletePackageGroupOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeletePackageGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeletePackageGroup(context.Background(), &DeletePackageGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeletePackageGroup.response", err)
	}
}

func TestCheckResponseSnapshot_DeletePackageVersions(t *testing.T) {
	want := &DeletePackageVersionsOutput{
		SuccessfulVersions: map[string]types.SuccessfulPackageVersionInfo{
			"key0": {
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
			},
		},
		FailedVersions: map[string]types.PackageVersionError{
			"key0": {
				ErrorCode:    types.PackageVersionErrorCode("ALREADY_EXISTS"),
				ErrorMessage: ptr.String("__ErrorMessage__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeletePackageVersions.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeletePackageVersions(context.Background(), &DeletePackageVersionsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeletePackageVersions.response", err)
	}
}

func TestCheckResponseSnapshot_DeleteRepository(t *testing.T) {
	want := &DeleteRepositoryOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeleteRepository.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeleteRepository(context.Background(), &DeleteRepositoryInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeleteRepository.response", err)
	}
}

func TestCheckResponseSnapshot_DeleteRepositoryPermissionsPolicy(t *testing.T) {
	want := &DeleteRepositoryPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DeleteRepositoryPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DeleteRepositoryPermissionsPolicy(context.Background(), &DeleteRepositoryPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DeleteRepositoryPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_DescribeDomain(t *testing.T) {
	want := &DescribeDomainOutput{
		Domain: &types.DomainDescription{
			Name:            ptr.String("__Name__"),
			Owner:           ptr.String("__Owner__"),
			Arn:             ptr.String("__Arn__"),
			Status:          types.DomainStatus("Active"),
			CreatedTime:     ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			EncryptionKey:   ptr.String("__EncryptionKey__"),
			RepositoryCount: 1,
			AssetSizeBytes:  1,
			S3BucketArn:     ptr.String("__S3BucketArn__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DescribeDomain.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DescribeDomain(context.Background(), &DescribeDomainInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DescribeDomain.response", err)
	}
}

func TestCheckResponseSnapshot_DescribePackage(t *testing.T) {
	want := &DescribePackageOutput{
		Package: &types.PackageDescription{
			Format:    types.PackageFormat("npm"),
			Namespace: ptr.String("__Namespace__"),
			Name:      ptr.String("__Name__"),
			OriginConfiguration: &types.PackageOriginConfiguration{
				Restrictions: &types.PackageOriginRestrictions{
					Publish:  types.AllowPublish("ALLOW"),
					Upstream: types.AllowUpstream("ALLOW"),
				},
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DescribePackage.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DescribePackage(context.Background(), &DescribePackageInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DescribePackage.response", err)
	}
}

func TestCheckResponseSnapshot_DescribePackageGroup(t *testing.T) {
	want := &DescribePackageGroupOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DescribePackageGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DescribePackageGroup(context.Background(), &DescribePackageGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DescribePackageGroup.response", err)
	}
}

func TestCheckResponseSnapshot_DescribePackageVersion(t *testing.T) {
	want := &DescribePackageVersionOutput{
		PackageVersion: &types.PackageVersionDescription{
			Format:               types.PackageFormat("npm"),
			Namespace:            ptr.String("__Namespace__"),
			PackageName:          ptr.String("__PackageName__"),
			DisplayName:          ptr.String("__DisplayName__"),
			Version:              ptr.String("__Version__"),
			Summary:              ptr.String("__Summary__"),
			HomePage:             ptr.String("__HomePage__"),
			SourceCodeRepository: ptr.String("__SourceCodeRepository__"),
			PublishedTime:        ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			Licenses: []types.LicenseInfo{
				{
					Name: ptr.String("__Name__"),
					Url:  ptr.String("__Url__"),
				},
				{
					Name: ptr.String("__Name__"),
					Url:  ptr.String("__Url__"),
				},
			},
			Revision: ptr.String("__Revision__"),
			Status:   types.PackageVersionStatus("Published"),
			Origin: &types.PackageVersionOrigin{
				DomainEntryPoint: &types.DomainEntryPoint{
					RepositoryName:         ptr.String("__RepositoryName__"),
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
				},
				OriginType: types.PackageVersionOriginType("INTERNAL"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DescribePackageVersion.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DescribePackageVersion(context.Background(), &DescribePackageVersionInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DescribePackageVersion.response", err)
	}
}

func TestCheckResponseSnapshot_DescribeRepository(t *testing.T) {
	want := &DescribeRepositoryOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DescribeRepository.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DescribeRepository(context.Background(), &DescribeRepositoryInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DescribeRepository.response", err)
	}
}

func TestCheckResponseSnapshot_DisassociateExternalConnection(t *testing.T) {
	want := &DisassociateExternalConnectionOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DisassociateExternalConnection.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DisassociateExternalConnection(context.Background(), &DisassociateExternalConnectionInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DisassociateExternalConnection.response", err)
	}
}

func TestCheckResponseSnapshot_DisposePackageVersions(t *testing.T) {
	want := &DisposePackageVersionsOutput{
		SuccessfulVersions: map[string]types.SuccessfulPackageVersionInfo{
			"key0": {
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
			},
		},
		FailedVersions: map[string]types.PackageVersionError{
			"key0": {
				ErrorCode:    types.PackageVersionErrorCode("ALREADY_EXISTS"),
				ErrorMessage: ptr.String("__ErrorMessage__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("DisposePackageVersions.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.DisposePackageVersions(context.Background(), &DisposePackageVersionsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "DisposePackageVersions.response", err)
	}
}

func TestCheckResponseSnapshot_GetAssociatedPackageGroup(t *testing.T) {
	want := &GetAssociatedPackageGroupOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
		AssociationType: types.PackageGroupAssociationType("STRONG"),
	}
	status, header, body, err := serdeRespReadSnapshot("GetAssociatedPackageGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetAssociatedPackageGroup(context.Background(), &GetAssociatedPackageGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetAssociatedPackageGroup.response", err)
	}
}

func TestCheckResponseSnapshot_GetAuthorizationToken(t *testing.T) {
	want := &GetAuthorizationTokenOutput{
		AuthorizationToken: ptr.String("__AuthorizationToken__"),
		Expiration:         ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
	}
	status, header, body, err := serdeRespReadSnapshot("GetAuthorizationToken.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetAuthorizationToken(context.Background(), &GetAuthorizationTokenInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetAuthorizationToken.response", err)
	}
}

func TestCheckResponseSnapshot_GetDomainPermissionsPolicy(t *testing.T) {
	want := &GetDomainPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("GetDomainPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetDomainPermissionsPolicy(context.Background(), &GetDomainPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetDomainPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_GetPackageVersionAsset(t *testing.T) {
	want := &GetPackageVersionAssetOutput{
		AssetName:              ptr.String("__AssetName__"),
		PackageVersion:         ptr.String("__PackageVersion__"),
		PackageVersionRevision: ptr.String("__PackageVersionRevision__"),
	}
	status, header, body, err := serdeRespReadSnapshot("GetPackageVersionAsset.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetPackageVersionAsset(context.Background(), &GetPackageVersionAssetInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetPackageVersionAsset.response", err)
	}
}

func TestCheckResponseSnapshot_GetPackageVersionReadme(t *testing.T) {
	want := &GetPackageVersionReadmeOutput{
		Format:          types.PackageFormat("npm"),
		Namespace:       ptr.String("__Namespace__"),
		Package:         ptr.String("__Package__"),
		Version:         ptr.String("__Version__"),
		VersionRevision: ptr.String("__VersionRevision__"),
		Readme:          ptr.String("__Readme__"),
	}
	status, header, body, err := serdeRespReadSnapshot("GetPackageVersionReadme.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetPackageVersionReadme(context.Background(), &GetPackageVersionReadmeInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetPackageVersionReadme.response", err)
	}
}

func TestCheckResponseSnapshot_GetRepositoryEndpoint(t *testing.T) {
	want := &GetRepositoryEndpointOutput{
		RepositoryEndpoint: ptr.String("__RepositoryEndpoint__"),
	}
	status, header, body, err := serdeRespReadSnapshot("GetRepositoryEndpoint.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetRepositoryEndpoint(context.Background(), &GetRepositoryEndpointInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetRepositoryEndpoint.response", err)
	}
}

func TestCheckResponseSnapshot_GetRepositoryPermissionsPolicy(t *testing.T) {
	want := &GetRepositoryPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("GetRepositoryPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.GetRepositoryPermissionsPolicy(context.Background(), &GetRepositoryPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "GetRepositoryPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_ListAllowedRepositoriesForGroup(t *testing.T) {
	want := &ListAllowedRepositoriesForGroupOutput{
		AllowedRepositories: []string{
			"__Member__",
			"__Member__",
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListAllowedRepositoriesForGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListAllowedRepositoriesForGroup(context.Background(), &ListAllowedRepositoriesForGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListAllowedRepositoriesForGroup.response", err)
	}
}

func TestCheckResponseSnapshot_ListAssociatedPackages(t *testing.T) {
	want := &ListAssociatedPackagesOutput{
		Packages: []types.AssociatedPackage{
			{
				Format:          types.PackageFormat("npm"),
				Namespace:       ptr.String("__Namespace__"),
				Package:         ptr.String("__Package__"),
				AssociationType: types.PackageGroupAssociationType("STRONG"),
			},
			{
				Format:          types.PackageFormat("npm"),
				Namespace:       ptr.String("__Namespace__"),
				Package:         ptr.String("__Package__"),
				AssociationType: types.PackageGroupAssociationType("STRONG"),
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListAssociatedPackages.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListAssociatedPackages(context.Background(), &ListAssociatedPackagesInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListAssociatedPackages.response", err)
	}
}

func TestCheckResponseSnapshot_ListDomains(t *testing.T) {
	want := &ListDomainsOutput{
		Domains: []types.DomainSummary{
			{
				Name:          ptr.String("__Name__"),
				Owner:         ptr.String("__Owner__"),
				Arn:           ptr.String("__Arn__"),
				Status:        types.DomainStatus("Active"),
				CreatedTime:   ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				EncryptionKey: ptr.String("__EncryptionKey__"),
			},
			{
				Name:          ptr.String("__Name__"),
				Owner:         ptr.String("__Owner__"),
				Arn:           ptr.String("__Arn__"),
				Status:        types.DomainStatus("Active"),
				CreatedTime:   ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				EncryptionKey: ptr.String("__EncryptionKey__"),
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListDomains.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListDomains(context.Background(), &ListDomainsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListDomains.response", err)
	}
}

func TestCheckResponseSnapshot_ListPackageGroups(t *testing.T) {
	want := &ListPackageGroupsOutput{
		PackageGroups: []types.PackageGroupSummary{
			{
				Arn:         ptr.String("__Arn__"),
				Pattern:     ptr.String("__Pattern__"),
				DomainName:  ptr.String("__DomainName__"),
				DomainOwner: ptr.String("__DomainOwner__"),
				CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				ContactInfo: ptr.String("__ContactInfo__"),
				Description: ptr.String("__Description__"),
				OriginConfiguration: &types.PackageGroupOriginConfiguration{
					Restrictions: map[string]types.PackageGroupOriginRestriction{
						"key0": {
							Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
							EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
							InheritedFrom: &types.PackageGroupReference{
								Arn:     ptr.String("__Arn__"),
								Pattern: ptr.String("__Pattern__"),
							},
							RepositoriesCount: ptr.Int64(1),
						},
					},
				},
				Parent: &types.PackageGroupReference{
					Arn:     ptr.String("__Arn__"),
					Pattern: ptr.String("__Pattern__"),
				},
			},
			{
				Arn:         ptr.String("__Arn__"),
				Pattern:     ptr.String("__Pattern__"),
				DomainName:  ptr.String("__DomainName__"),
				DomainOwner: ptr.String("__DomainOwner__"),
				CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				ContactInfo: ptr.String("__ContactInfo__"),
				Description: ptr.String("__Description__"),
				OriginConfiguration: &types.PackageGroupOriginConfiguration{
					Restrictions: map[string]types.PackageGroupOriginRestriction{
						"key0": {
							Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
							EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
							InheritedFrom: &types.PackageGroupReference{
								Arn:     ptr.String("__Arn__"),
								Pattern: ptr.String("__Pattern__"),
							},
							RepositoriesCount: ptr.Int64(1),
						},
					},
				},
				Parent: &types.PackageGroupReference{
					Arn:     ptr.String("__Arn__"),
					Pattern: ptr.String("__Pattern__"),
				},
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListPackageGroups.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListPackageGroups(context.Background(), &ListPackageGroupsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListPackageGroups.response", err)
	}
}

func TestCheckResponseSnapshot_ListPackageVersionAssets(t *testing.T) {
	want := &ListPackageVersionAssetsOutput{
		Format:          types.PackageFormat("npm"),
		Namespace:       ptr.String("__Namespace__"),
		Package:         ptr.String("__Package__"),
		Version:         ptr.String("__Version__"),
		VersionRevision: ptr.String("__VersionRevision__"),
		NextToken:       ptr.String("__NextToken__"),
		Assets: []types.AssetSummary{
			{
				Name: ptr.String("__Name__"),
				Size: ptr.Int64(1),
				Hashes: map[string]string{
					"key0": "__Value__",
				},
			},
			{
				Name: ptr.String("__Name__"),
				Size: ptr.Int64(1),
				Hashes: map[string]string{
					"key0": "__Value__",
				},
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("ListPackageVersionAssets.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListPackageVersionAssets(context.Background(), &ListPackageVersionAssetsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListPackageVersionAssets.response", err)
	}
}

func TestCheckResponseSnapshot_ListPackageVersionDependencies(t *testing.T) {
	want := &ListPackageVersionDependenciesOutput{
		Format:          types.PackageFormat("npm"),
		Namespace:       ptr.String("__Namespace__"),
		Package:         ptr.String("__Package__"),
		Version:         ptr.String("__Version__"),
		VersionRevision: ptr.String("__VersionRevision__"),
		NextToken:       ptr.String("__NextToken__"),
		Dependencies: []types.PackageDependency{
			{
				Namespace:          ptr.String("__Namespace__"),
				Package:            ptr.String("__Package__"),
				DependencyType:     ptr.String("__DependencyType__"),
				VersionRequirement: ptr.String("__VersionRequirement__"),
			},
			{
				Namespace:          ptr.String("__Namespace__"),
				Package:            ptr.String("__Package__"),
				DependencyType:     ptr.String("__DependencyType__"),
				VersionRequirement: ptr.String("__VersionRequirement__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("ListPackageVersionDependencies.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListPackageVersionDependencies(context.Background(), &ListPackageVersionDependenciesInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListPackageVersionDependencies.response", err)
	}
}

func TestCheckResponseSnapshot_ListPackageVersions(t *testing.T) {
	want := &ListPackageVersionsOutput{
		DefaultDisplayVersion: ptr.String("__DefaultDisplayVersion__"),
		Format:                types.PackageFormat("npm"),
		Namespace:             ptr.String("__Namespace__"),
		Package:               ptr.String("__Package__"),
		Versions: []types.PackageVersionSummary{
			{
				Version:  ptr.String("__Version__"),
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
				Origin: &types.PackageVersionOrigin{
					DomainEntryPoint: &types.DomainEntryPoint{
						RepositoryName:         ptr.String("__RepositoryName__"),
						ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					},
					OriginType: types.PackageVersionOriginType("INTERNAL"),
				},
			},
			{
				Version:  ptr.String("__Version__"),
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
				Origin: &types.PackageVersionOrigin{
					DomainEntryPoint: &types.DomainEntryPoint{
						RepositoryName:         ptr.String("__RepositoryName__"),
						ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					},
					OriginType: types.PackageVersionOriginType("INTERNAL"),
				},
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListPackageVersions.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListPackageVersions(context.Background(), &ListPackageVersionsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListPackageVersions.response", err)
	}
}

func TestCheckResponseSnapshot_ListPackages(t *testing.T) {
	want := &ListPackagesOutput{
		Packages: []types.PackageSummary{
			{
				Format:    types.PackageFormat("npm"),
				Namespace: ptr.String("__Namespace__"),
				Package:   ptr.String("__Package__"),
				OriginConfiguration: &types.PackageOriginConfiguration{
					Restrictions: &types.PackageOriginRestrictions{
						Publish:  types.AllowPublish("ALLOW"),
						Upstream: types.AllowUpstream("ALLOW"),
					},
				},
			},
			{
				Format:    types.PackageFormat("npm"),
				Namespace: ptr.String("__Namespace__"),
				Package:   ptr.String("__Package__"),
				OriginConfiguration: &types.PackageOriginConfiguration{
					Restrictions: &types.PackageOriginRestrictions{
						Publish:  types.AllowPublish("ALLOW"),
						Upstream: types.AllowUpstream("ALLOW"),
					},
				},
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListPackages.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListPackages(context.Background(), &ListPackagesInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListPackages.response", err)
	}
}

func TestCheckResponseSnapshot_ListRepositories(t *testing.T) {
	want := &ListRepositoriesOutput{
		Repositories: []types.RepositorySummary{
			{
				Name:                 ptr.String("__Name__"),
				AdministratorAccount: ptr.String("__AdministratorAccount__"),
				DomainName:           ptr.String("__DomainName__"),
				DomainOwner:          ptr.String("__DomainOwner__"),
				Arn:                  ptr.String("__Arn__"),
				Description:          ptr.String("__Description__"),
				CreatedTime:          ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			},
			{
				Name:                 ptr.String("__Name__"),
				AdministratorAccount: ptr.String("__AdministratorAccount__"),
				DomainName:           ptr.String("__DomainName__"),
				DomainOwner:          ptr.String("__DomainOwner__"),
				Arn:                  ptr.String("__Arn__"),
				Description:          ptr.String("__Description__"),
				CreatedTime:          ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListRepositories.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListRepositories(context.Background(), &ListRepositoriesInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListRepositories.response", err)
	}
}

func TestCheckResponseSnapshot_ListRepositoriesInDomain(t *testing.T) {
	want := &ListRepositoriesInDomainOutput{
		Repositories: []types.RepositorySummary{
			{
				Name:                 ptr.String("__Name__"),
				AdministratorAccount: ptr.String("__AdministratorAccount__"),
				DomainName:           ptr.String("__DomainName__"),
				DomainOwner:          ptr.String("__DomainOwner__"),
				Arn:                  ptr.String("__Arn__"),
				Description:          ptr.String("__Description__"),
				CreatedTime:          ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			},
			{
				Name:                 ptr.String("__Name__"),
				AdministratorAccount: ptr.String("__AdministratorAccount__"),
				DomainName:           ptr.String("__DomainName__"),
				DomainOwner:          ptr.String("__DomainOwner__"),
				Arn:                  ptr.String("__Arn__"),
				Description:          ptr.String("__Description__"),
				CreatedTime:          ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListRepositoriesInDomain.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListRepositoriesInDomain(context.Background(), &ListRepositoriesInDomainInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListRepositoriesInDomain.response", err)
	}
}

func TestCheckResponseSnapshot_ListSubPackageGroups(t *testing.T) {
	want := &ListSubPackageGroupsOutput{
		PackageGroups: []types.PackageGroupSummary{
			{
				Arn:         ptr.String("__Arn__"),
				Pattern:     ptr.String("__Pattern__"),
				DomainName:  ptr.String("__DomainName__"),
				DomainOwner: ptr.String("__DomainOwner__"),
				CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				ContactInfo: ptr.String("__ContactInfo__"),
				Description: ptr.String("__Description__"),
				OriginConfiguration: &types.PackageGroupOriginConfiguration{
					Restrictions: map[string]types.PackageGroupOriginRestriction{
						"key0": {
							Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
							EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
							InheritedFrom: &types.PackageGroupReference{
								Arn:     ptr.String("__Arn__"),
								Pattern: ptr.String("__Pattern__"),
							},
							RepositoriesCount: ptr.Int64(1),
						},
					},
				},
				Parent: &types.PackageGroupReference{
					Arn:     ptr.String("__Arn__"),
					Pattern: ptr.String("__Pattern__"),
				},
			},
			{
				Arn:         ptr.String("__Arn__"),
				Pattern:     ptr.String("__Pattern__"),
				DomainName:  ptr.String("__DomainName__"),
				DomainOwner: ptr.String("__DomainOwner__"),
				CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
				ContactInfo: ptr.String("__ContactInfo__"),
				Description: ptr.String("__Description__"),
				OriginConfiguration: &types.PackageGroupOriginConfiguration{
					Restrictions: map[string]types.PackageGroupOriginRestriction{
						"key0": {
							Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
							EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
							InheritedFrom: &types.PackageGroupReference{
								Arn:     ptr.String("__Arn__"),
								Pattern: ptr.String("__Pattern__"),
							},
							RepositoriesCount: ptr.Int64(1),
						},
					},
				},
				Parent: &types.PackageGroupReference{
					Arn:     ptr.String("__Arn__"),
					Pattern: ptr.String("__Pattern__"),
				},
			},
		},
		NextToken: ptr.String("__NextToken__"),
	}
	status, header, body, err := serdeRespReadSnapshot("ListSubPackageGroups.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListSubPackageGroups(context.Background(), &ListSubPackageGroupsInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListSubPackageGroups.response", err)
	}
}

func TestCheckResponseSnapshot_ListTagsForResource(t *testing.T) {
	want := &ListTagsForResourceOutput{
		Tags: []types.Tag{
			{
				Key:   ptr.String("__Key__"),
				Value: ptr.String("__Value__"),
			},
			{
				Key:   ptr.String("__Key__"),
				Value: ptr.String("__Value__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("ListTagsForResource.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.ListTagsForResource(context.Background(), &ListTagsForResourceInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "ListTagsForResource.response", err)
	}
}

func TestCheckResponseSnapshot_PublishPackageVersion(t *testing.T) {
	want := &PublishPackageVersionOutput{
		Format:          types.PackageFormat("npm"),
		Namespace:       ptr.String("__Namespace__"),
		Package:         ptr.String("__Package__"),
		Version:         ptr.String("__Version__"),
		VersionRevision: ptr.String("__VersionRevision__"),
		Status:          types.PackageVersionStatus("Published"),
		Asset: &types.AssetSummary{
			Name: ptr.String("__Name__"),
			Size: ptr.Int64(1),
			Hashes: map[string]string{
				"key0": "__Value__",
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("PublishPackageVersion.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.PublishPackageVersion(context.Background(), &PublishPackageVersionInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "PublishPackageVersion.response", err)
	}
}

func TestCheckResponseSnapshot_PutDomainPermissionsPolicy(t *testing.T) {
	want := &PutDomainPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("PutDomainPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.PutDomainPermissionsPolicy(context.Background(), &PutDomainPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "PutDomainPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_PutPackageOriginConfiguration(t *testing.T) {
	want := &PutPackageOriginConfigurationOutput{
		OriginConfiguration: &types.PackageOriginConfiguration{
			Restrictions: &types.PackageOriginRestrictions{
				Publish:  types.AllowPublish("ALLOW"),
				Upstream: types.AllowUpstream("ALLOW"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("PutPackageOriginConfiguration.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.PutPackageOriginConfiguration(context.Background(), &PutPackageOriginConfigurationInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "PutPackageOriginConfiguration.response", err)
	}
}

func TestCheckResponseSnapshot_PutRepositoryPermissionsPolicy(t *testing.T) {
	want := &PutRepositoryPermissionsPolicyOutput{
		Policy: &types.ResourcePolicy{
			ResourceArn: ptr.String("__ResourceArn__"),
			Revision:    ptr.String("__Revision__"),
			Document:    ptr.String("__Document__"),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("PutRepositoryPermissionsPolicy.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.PutRepositoryPermissionsPolicy(context.Background(), &PutRepositoryPermissionsPolicyInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "PutRepositoryPermissionsPolicy.response", err)
	}
}

func TestCheckResponseSnapshot_TagResource(t *testing.T) {
	want := &TagResourceOutput{}
	status, header, body, err := serdeRespReadSnapshot("TagResource.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.TagResource(context.Background(), &TagResourceInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "TagResource.response", err)
	}
}

func TestCheckResponseSnapshot_UntagResource(t *testing.T) {
	want := &UntagResourceOutput{}
	status, header, body, err := serdeRespReadSnapshot("UntagResource.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.UntagResource(context.Background(), &UntagResourceInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "UntagResource.response", err)
	}
}

func TestCheckResponseSnapshot_UpdatePackageGroup(t *testing.T) {
	want := &UpdatePackageGroupOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("UpdatePackageGroup.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.UpdatePackageGroup(context.Background(), &UpdatePackageGroupInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "UpdatePackageGroup.response", err)
	}
}

func TestCheckResponseSnapshot_UpdatePackageGroupOriginConfiguration(t *testing.T) {
	want := &UpdatePackageGroupOriginConfigurationOutput{
		PackageGroup: &types.PackageGroupDescription{
			Arn:         ptr.String("__Arn__"),
			Pattern:     ptr.String("__Pattern__"),
			DomainName:  ptr.String("__DomainName__"),
			DomainOwner: ptr.String("__DomainOwner__"),
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
			ContactInfo: ptr.String("__ContactInfo__"),
			Description: ptr.String("__Description__"),
			OriginConfiguration: &types.PackageGroupOriginConfiguration{
				Restrictions: map[string]types.PackageGroupOriginRestriction{
					"key0": {
						Mode:          types.PackageGroupOriginRestrictionMode("ALLOW"),
						EffectiveMode: types.PackageGroupOriginRestrictionMode("ALLOW"),
						InheritedFrom: &types.PackageGroupReference{
							Arn:     ptr.String("__Arn__"),
							Pattern: ptr.String("__Pattern__"),
						},
						RepositoriesCount: ptr.Int64(1),
					},
				},
			},
			Parent: &types.PackageGroupReference{
				Arn:     ptr.String("__Arn__"),
				Pattern: ptr.String("__Pattern__"),
			},
		},
		AllowedRepositoryUpdates: map[string]map[string][]string{
			"key0": {
				"key0": {
					"__Member__",
					"__Member__",
				},
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("UpdatePackageGroupOriginConfiguration.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.UpdatePackageGroupOriginConfiguration(context.Background(), &UpdatePackageGroupOriginConfigurationInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "UpdatePackageGroupOriginConfiguration.response", err)
	}
}

func TestCheckResponseSnapshot_UpdatePackageVersionsStatus(t *testing.T) {
	want := &UpdatePackageVersionsStatusOutput{
		SuccessfulVersions: map[string]types.SuccessfulPackageVersionInfo{
			"key0": {
				Revision: ptr.String("__Revision__"),
				Status:   types.PackageVersionStatus("Published"),
			},
		},
		FailedVersions: map[string]types.PackageVersionError{
			"key0": {
				ErrorCode:    types.PackageVersionErrorCode("ALREADY_EXISTS"),
				ErrorMessage: ptr.String("__ErrorMessage__"),
			},
		},
	}
	status, header, body, err := serdeRespReadSnapshot("UpdatePackageVersionsStatus.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.UpdatePackageVersionsStatus(context.Background(), &UpdatePackageVersionsStatusInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "UpdatePackageVersionsStatus.response", err)
	}
}

func TestCheckResponseSnapshot_UpdateRepository(t *testing.T) {
	want := &UpdateRepositoryOutput{
		Repository: &types.RepositoryDescription{
			Name:                 ptr.String("__Name__"),
			AdministratorAccount: ptr.String("__AdministratorAccount__"),
			DomainName:           ptr.String("__DomainName__"),
			DomainOwner:          ptr.String("__DomainOwner__"),
			Arn:                  ptr.String("__Arn__"),
			Description:          ptr.String("__Description__"),
			Upstreams: []types.UpstreamRepositoryInfo{
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
				{
					RepositoryName: ptr.String("__RepositoryName__"),
				},
			},
			ExternalConnections: []types.RepositoryExternalConnectionInfo{
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
				{
					ExternalConnectionName: ptr.String("__ExternalConnectionName__"),
					PackageFormat:          types.PackageFormat("npm"),
					Status:                 types.ExternalConnectionStatus("Available"),
				},
			},
			CreatedTime: ptr.Time(time.Date(2000, 1, 1, 0, 0, 0, 0, time.UTC)),
		},
	}
	status, header, body, err := serdeRespReadSnapshot("UpdateRepository.response")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	got, err := svc.UpdateRepository(context.Background(), &UpdateRepositoryInput{})
	if err != nil {
		t.Fatal(err)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("response snapshot mismatch for %s: %v", "UpdateRepository.response", err)
	}
}

func TestCheckResponseSnapshot_Error_AccessDeniedException(t *testing.T) {
	want := &types.AccessDeniedException{
		Message: ptr.String("__Message__"),
	}
	status, header, body, err := serdeRespReadSnapshot("AccessDeniedException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.AccessDeniedException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.AccessDeniedException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "AccessDeniedException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_ConflictException(t *testing.T) {
	want := &types.ConflictException{
		Message:      ptr.String("__Message__"),
		ResourceId:   ptr.String("__ResourceId__"),
		ResourceType: types.ResourceType("domain"),
	}
	status, header, body, err := serdeRespReadSnapshot("ConflictException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.ConflictException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.ConflictException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "ConflictException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_InternalServerException(t *testing.T) {
	want := &types.InternalServerException{
		Message: ptr.String("__Message__"),
	}
	status, header, body, err := serdeRespReadSnapshot("InternalServerException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.InternalServerException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.InternalServerException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "InternalServerException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_ResourceNotFoundException(t *testing.T) {
	want := &types.ResourceNotFoundException{
		Message:      ptr.String("__Message__"),
		ResourceId:   ptr.String("__ResourceId__"),
		ResourceType: types.ResourceType("domain"),
	}
	status, header, body, err := serdeRespReadSnapshot("ResourceNotFoundException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.ResourceNotFoundException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.ResourceNotFoundException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "ResourceNotFoundException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_ServiceQuotaExceededException(t *testing.T) {
	want := &types.ServiceQuotaExceededException{
		Message:      ptr.String("__Message__"),
		ResourceId:   ptr.String("__ResourceId__"),
		ResourceType: types.ResourceType("domain"),
	}
	status, header, body, err := serdeRespReadSnapshot("ServiceQuotaExceededException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.ServiceQuotaExceededException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.ServiceQuotaExceededException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "ServiceQuotaExceededException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_ThrottlingException(t *testing.T) {
	want := &types.ThrottlingException{
		Message:           ptr.String("__Message__"),
		RetryAfterSeconds: ptr.Int32(1),
	}
	status, header, body, err := serdeRespReadSnapshot("ThrottlingException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.ThrottlingException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.ThrottlingException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "ThrottlingException.error", err)
	}
}

func TestCheckResponseSnapshot_Error_ValidationException(t *testing.T) {
	want := &types.ValidationException{
		Message: ptr.String("__Message__"),
		Reason:  types.ValidationExceptionReason("CANNOT_PARSE"),
	}
	status, header, body, err := serdeRespReadSnapshot("ValidationException.error")
	if errors.Is(err, fs.ErrNotExist) {
		t.Skip("no response snapshot fixture")
	}
	if err != nil {
		t.Fatal(err)
	}
	svc := serdeRespClient(status, header, body)
	_, opErr := svc.AssociateExternalConnection(context.Background(), &AssociateExternalConnectionInput{})
	if opErr == nil {
		t.Fatal("expected error, got nil")
	}
	var got *types.ValidationException
	if !errors.As(opErr, &got) {
		t.Fatalf("expected types.ValidationException, got %v", opErr)
	}
	if err := smithytesting.CompareValues(want, got); err != nil {
		t.Errorf("error response snapshot mismatch for %s: %v", "ValidationException.error", err)
	}
}
