package v1

import "cloud.google.com/go/storage/internal/test/conformance"

Index

Variables

var (
	UrlStyle_name = map[int32]string{
		0: "PATH_STYLE",
		1: "VIRTUAL_HOSTED_STYLE",
		2: "BUCKET_BOUND_HOSTNAME",
	}
	UrlStyle_value = map[string]int32{
		"PATH_STYLE":            0,
		"VIRTUAL_HOSTED_STYLE":  1,
		"BUCKET_BOUND_HOSTNAME": 2,
	}
)

Enum value maps for UrlStyle.

var (
	Resource_name = map[int32]string{
		0: "BUCKET",
		1: "OBJECT",
		2: "NOTIFICATION",
		3: "HMAC_KEY",
	}
	Resource_value = map[string]int32{
		"BUCKET":       0,
		"OBJECT":       1,
		"NOTIFICATION": 2,
		"HMAC_KEY":     3,
	}
)

Enum value maps for Resource.

var File_test_proto protoreflect.FileDescriptor

Types

type ConditionalMatches

type ConditionalMatches struct {
	Expression []string `protobuf:"bytes,1,rep,name=expression,proto3" json:"expression,omitempty"`
	// contains filtered or unexported fields
}

func (*ConditionalMatches) Descriptor

func (*ConditionalMatches) Descriptor() ([]byte, []int)

Deprecated: Use ConditionalMatches.ProtoReflect.Descriptor instead.

func (*ConditionalMatches) GetExpression

func (x *ConditionalMatches) GetExpression() []string

func (*ConditionalMatches) ProtoMessage

func (*ConditionalMatches) ProtoMessage()

func (*ConditionalMatches) ProtoReflect

func (x *ConditionalMatches) ProtoReflect() protoreflect.Message

func (*ConditionalMatches) Reset

func (x *ConditionalMatches) Reset()

func (*ConditionalMatches) String

func (x *ConditionalMatches) String() string

type InstructionList

type InstructionList struct {
	Instructions []string `protobuf:"bytes,1,rep,name=instructions,proto3" json:"instructions,omitempty"`
	// contains filtered or unexported fields
}

A list of instructions to send as headers to the GCS emulator. Each instruction will force a specified failure for that request.

func (*InstructionList) Descriptor

func (*InstructionList) Descriptor() ([]byte, []int)

Deprecated: Use InstructionList.ProtoReflect.Descriptor instead.

func (*InstructionList) GetInstructions

func (x *InstructionList) GetInstructions() []string

func (*InstructionList) ProtoMessage

func (*InstructionList) ProtoMessage()

func (*InstructionList) ProtoReflect

func (x *InstructionList) ProtoReflect() protoreflect.Message

func (*InstructionList) Reset

func (x *InstructionList) Reset()

func (*InstructionList) String

func (x *InstructionList) String() string

type Method

type Method struct {
	Name      string     `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // e.g. storage.objects.get
	Resources []Resource `protobuf:"varint,2,rep,packed,name=resources,proto3,enum=google.cloud.conformance.storage.v1.Resource" json:"resources,omitempty"`
	Group     string     `protobuf:"bytes,3,opt,name=group,proto3" json:"group,omitempty"` // e.g. storage.resumable.upload
	// contains filtered or unexported fields
}

A particular storage API method and required resources in order to test it. Methods must be implemented in tests for each language.

func (*Method) Descriptor

func (*Method) Descriptor() ([]byte, []int)

Deprecated: Use Method.ProtoReflect.Descriptor instead.

func (*Method) GetGroup

func (x *Method) GetGroup() string

func (*Method) GetName

func (x *Method) GetName() string

func (*Method) GetResources

func (x *Method) GetResources() []Resource

func (*Method) ProtoMessage

func (*Method) ProtoMessage()

func (*Method) ProtoReflect

func (x *Method) ProtoReflect() protoreflect.Message

func (*Method) Reset

func (x *Method) Reset()

func (*Method) String

func (x *Method) String() string

type PolicyConditions

type PolicyConditions struct {
	ContentLengthRange []int32  `protobuf:"varint,1,rep,packed,name=contentLengthRange,proto3" json:"contentLengthRange,omitempty"`
	StartsWith         []string `protobuf:"bytes,2,rep,name=startsWith,proto3" json:"startsWith,omitempty"`
	// contains filtered or unexported fields
}

func (*PolicyConditions) Descriptor

func (*PolicyConditions) Descriptor() ([]byte, []int)

Deprecated: Use PolicyConditions.ProtoReflect.Descriptor instead.

func (*PolicyConditions) GetContentLengthRange

func (x *PolicyConditions) GetContentLengthRange() []int32

func (*PolicyConditions) GetStartsWith

func (x *PolicyConditions) GetStartsWith() []string

func (*PolicyConditions) ProtoMessage

func (*PolicyConditions) ProtoMessage()

func (*PolicyConditions) ProtoReflect

func (x *PolicyConditions) ProtoReflect() protoreflect.Message

func (*PolicyConditions) Reset

func (x *PolicyConditions) Reset()

func (*PolicyConditions) String

func (x *PolicyConditions) String() string

type PolicyInput

type PolicyInput struct {

	// http or https
	Scheme              string                 `protobuf:"bytes,1,opt,name=scheme,proto3" json:"scheme,omitempty"`
	UrlStyle            UrlStyle               `protobuf:"varint,2,opt,name=urlStyle,proto3,enum=google.cloud.conformance.storage.v1.UrlStyle" json:"urlStyle,omitempty"`
	BucketBoundHostname string                 `protobuf:"bytes,3,opt,name=bucketBoundHostname,proto3" json:"bucketBoundHostname,omitempty"`
	Bucket              string                 `protobuf:"bytes,4,opt,name=bucket,proto3" json:"bucket,omitempty"`
	Object              string                 `protobuf:"bytes,5,opt,name=object,proto3" json:"object,omitempty"`
	Expiration          int32                  `protobuf:"varint,6,opt,name=expiration,proto3" json:"expiration,omitempty"`
	Timestamp           *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// fields with strict equivalence which are added into
	// PolicyOutput.expectedDecodedPolicy to generate the
	// signature.
	// Expectations
	// E.1: Order them in lexigraphical order so it's the
	// signature can be verified across different language
	// implementations.
	Fields     map[string]string `protobuf:"bytes,8,rep,name=fields,proto3" json:"fields,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
	Conditions *PolicyConditions `protobuf:"bytes,9,opt,name=conditions,proto3" json:"conditions,omitempty"`
	// contains filtered or unexported fields
}

func (*PolicyInput) Descriptor

func (*PolicyInput) Descriptor() ([]byte, []int)

Deprecated: Use PolicyInput.ProtoReflect.Descriptor instead.

func (*PolicyInput) GetBucket

func (x *PolicyInput) GetBucket() string

func (*PolicyInput) GetBucketBoundHostname

func (x *PolicyInput) GetBucketBoundHostname() string

func (*PolicyInput) GetConditions

func (x *PolicyInput) GetConditions() *PolicyConditions

func (*PolicyInput) GetExpiration

func (x *PolicyInput) GetExpiration() int32

func (*PolicyInput) GetFields

func (x *PolicyInput) GetFields() map[string]string

func (*PolicyInput) GetObject

func (x *PolicyInput) GetObject() string

func (*PolicyInput) GetScheme

func (x *PolicyInput) GetScheme() string

func (*PolicyInput) GetTimestamp

func (x *PolicyInput) GetTimestamp() *timestamppb.Timestamp

func (*PolicyInput) GetUrlStyle

func (x *PolicyInput) GetUrlStyle() UrlStyle

func (*PolicyInput) ProtoMessage

func (*PolicyInput) ProtoMessage()

func (*PolicyInput) ProtoReflect

func (x *PolicyInput) ProtoReflect() protoreflect.Message

func (*PolicyInput) Reset

func (x *PolicyInput) Reset()

func (*PolicyInput) String

func (x *PolicyInput) String() string

type PolicyOutput

type PolicyOutput struct {
	Url                   string            `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
	Fields                map[string]string `protobuf:"bytes,2,rep,name=fields,proto3" json:"fields,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
	ExpectedDecodedPolicy string            `protobuf:"bytes,3,opt,name=expectedDecodedPolicy,proto3" json:"expectedDecodedPolicy,omitempty"`
	// contains filtered or unexported fields
}

func (*PolicyOutput) Descriptor

func (*PolicyOutput) Descriptor() ([]byte, []int)

Deprecated: Use PolicyOutput.ProtoReflect.Descriptor instead.

func (*PolicyOutput) GetExpectedDecodedPolicy

func (x *PolicyOutput) GetExpectedDecodedPolicy() string

func (*PolicyOutput) GetFields

func (x *PolicyOutput) GetFields() map[string]string

func (*PolicyOutput) GetUrl

func (x *PolicyOutput) GetUrl() string

func (*PolicyOutput) ProtoMessage

func (*PolicyOutput) ProtoMessage()

func (*PolicyOutput) ProtoReflect

func (x *PolicyOutput) ProtoReflect() protoreflect.Message

func (*PolicyOutput) Reset

func (x *PolicyOutput) Reset()

func (*PolicyOutput) String

func (x *PolicyOutput) String() string

type PostPolicyV4Test

type PostPolicyV4Test struct {
	Description  string        `protobuf:"bytes,1,opt,name=description,proto3" json:"description,omitempty"`
	PolicyInput  *PolicyInput  `protobuf:"bytes,2,opt,name=policyInput,proto3" json:"policyInput,omitempty"`
	PolicyOutput *PolicyOutput `protobuf:"bytes,3,opt,name=policyOutput,proto3" json:"policyOutput,omitempty"`
	// contains filtered or unexported fields
}

func (*PostPolicyV4Test) Descriptor

func (*PostPolicyV4Test) Descriptor() ([]byte, []int)

Deprecated: Use PostPolicyV4Test.ProtoReflect.Descriptor instead.

func (*PostPolicyV4Test) GetDescription

func (x *PostPolicyV4Test) GetDescription() string

func (*PostPolicyV4Test) GetPolicyInput

func (x *PostPolicyV4Test) GetPolicyInput() *PolicyInput

func (*PostPolicyV4Test) GetPolicyOutput

func (x *PostPolicyV4Test) GetPolicyOutput() *PolicyOutput

func (*PostPolicyV4Test) ProtoMessage

func (*PostPolicyV4Test) ProtoMessage()

func (*PostPolicyV4Test) ProtoReflect

func (x *PostPolicyV4Test) ProtoReflect() protoreflect.Message

func (*PostPolicyV4Test) Reset

func (x *PostPolicyV4Test) Reset()

func (*PostPolicyV4Test) String

func (x *PostPolicyV4Test) String() string

type Resource

type Resource int32

Test resources that are necessary for a method call. For example, storage.objects.get would require BUCKET and OBJECT.

const (
	Resource_BUCKET       Resource = 0
	Resource_OBJECT       Resource = 1
	Resource_NOTIFICATION Resource = 2
	Resource_HMAC_KEY     Resource = 3
)

func (Resource) Descriptor

func (Resource) Descriptor() protoreflect.EnumDescriptor

func (Resource) Enum

func (x Resource) Enum() *Resource

func (Resource) EnumDescriptor

func (Resource) EnumDescriptor() ([]byte, []int)

Deprecated: Use Resource.Descriptor instead.

func (Resource) Number

func (x Resource) Number() protoreflect.EnumNumber

func (Resource) String

func (x Resource) String() string

func (Resource) Type

type RetryTest

type RetryTest struct {

	// Scenario number
	Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// Human-readable description of the test case.
	Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
	// list of emulator instruction sets.
	Cases []*InstructionList `protobuf:"bytes,3,rep,name=cases,proto3" json:"cases,omitempty"`
	// List of API methods to be tested.
	Methods []*Method `protobuf:"bytes,4,rep,name=methods,proto3" json:"methods,omitempty"`
	// Whether a precondition is provided (for conditionally-idempotent methods
	// only).
	PreconditionProvided bool `protobuf:"varint,5,opt,name=preconditionProvided,proto3" json:"preconditionProvided,omitempty"`
	// Whether we expect the method calls to eventually succeed after the client
	// library retries.
	ExpectSuccess bool `protobuf:"varint,6,opt,name=expectSuccess,proto3" json:"expectSuccess,omitempty"`
	// contains filtered or unexported fields
}

Schema for a retry test, corresponding to a single scenario from the design doc.

func (*RetryTest) Descriptor

func (*RetryTest) Descriptor() ([]byte, []int)

Deprecated: Use RetryTest.ProtoReflect.Descriptor instead.

func (*RetryTest) GetCases

func (x *RetryTest) GetCases() []*InstructionList

func (*RetryTest) GetDescription

func (x *RetryTest) GetDescription() string

func (*RetryTest) GetExpectSuccess

func (x *RetryTest) GetExpectSuccess() bool

func (*RetryTest) GetId

func (x *RetryTest) GetId() int32

func (*RetryTest) GetMethods

func (x *RetryTest) GetMethods() []*Method

func (*RetryTest) GetPreconditionProvided

func (x *RetryTest) GetPreconditionProvided() bool

func (*RetryTest) ProtoMessage

func (*RetryTest) ProtoMessage()

func (*RetryTest) ProtoReflect

func (x *RetryTest) ProtoReflect() protoreflect.Message

func (*RetryTest) Reset

func (x *RetryTest) Reset()

func (*RetryTest) String

func (x *RetryTest) String() string

type RetryTests

type RetryTests struct {
	RetryTests []*RetryTest `protobuf:"bytes,1,rep,name=retryTests,proto3" json:"retryTests,omitempty"`
	// contains filtered or unexported fields
}

func (*RetryTests) Descriptor

func (*RetryTests) Descriptor() ([]byte, []int)

Deprecated: Use RetryTests.ProtoReflect.Descriptor instead.

func (*RetryTests) GetRetryTests

func (x *RetryTests) GetRetryTests() []*RetryTest

func (*RetryTests) ProtoMessage

func (*RetryTests) ProtoMessage()

func (*RetryTests) ProtoReflect

func (x *RetryTests) ProtoReflect() protoreflect.Message

func (*RetryTests) Reset

func (x *RetryTests) Reset()

func (*RetryTests) String

func (x *RetryTests) String() string

type SigningV4Test

type SigningV4Test struct {
	FileName                 string                 `protobuf:"bytes,1,opt,name=fileName,proto3" json:"fileName,omitempty"`
	Description              string                 `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
	Bucket                   string                 `protobuf:"bytes,3,opt,name=bucket,proto3" json:"bucket,omitempty"`
	Object                   string                 `protobuf:"bytes,4,opt,name=object,proto3" json:"object,omitempty"`
	Method                   string                 `protobuf:"bytes,5,opt,name=method,proto3" json:"method,omitempty"`
	Expiration               int64                  `protobuf:"varint,6,opt,name=expiration,proto3" json:"expiration,omitempty"`
	Timestamp                *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	ExpectedUrl              string                 `protobuf:"bytes,8,opt,name=expectedUrl,proto3" json:"expectedUrl,omitempty"`
	Headers                  map[string]string      `protobuf:"bytes,9,rep,name=headers,proto3" json:"headers,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
	QueryParameters          map[string]string      `protobuf:"bytes,10,rep,name=query_parameters,json=queryParameters,proto3" json:"query_parameters,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
	Scheme                   string                 `protobuf:"bytes,11,opt,name=scheme,proto3" json:"scheme,omitempty"`
	UrlStyle                 UrlStyle               `protobuf:"varint,12,opt,name=urlStyle,proto3,enum=google.cloud.conformance.storage.v1.UrlStyle" json:"urlStyle,omitempty"`
	BucketBoundHostname      string                 `protobuf:"bytes,13,opt,name=bucketBoundHostname,proto3" json:"bucketBoundHostname,omitempty"`
	ExpectedCanonicalRequest string                 `protobuf:"bytes,14,opt,name=expectedCanonicalRequest,proto3" json:"expectedCanonicalRequest,omitempty"`
	ExpectedStringToSign     string                 `protobuf:"bytes,15,opt,name=expectedStringToSign,proto3" json:"expectedStringToSign,omitempty"`
	Hostname                 string                 `protobuf:"bytes,16,opt,name=hostname,proto3" json:"hostname,omitempty"`
	ClientEndpoint           string                 `protobuf:"bytes,17,opt,name=clientEndpoint,proto3" json:"clientEndpoint,omitempty"`
	EmulatorHostname         string                 `protobuf:"bytes,18,opt,name=emulatorHostname,proto3" json:"emulatorHostname,omitempty"`
	UniverseDomain           string                 `protobuf:"bytes,19,opt,name=universeDomain,proto3" json:"universeDomain,omitempty"`
	// contains filtered or unexported fields
}

func (*SigningV4Test) Descriptor

func (*SigningV4Test) Descriptor() ([]byte, []int)

Deprecated: Use SigningV4Test.ProtoReflect.Descriptor instead.

func (*SigningV4Test) GetBucket

func (x *SigningV4Test) GetBucket() string

func (*SigningV4Test) GetBucketBoundHostname

func (x *SigningV4Test) GetBucketBoundHostname() string

func (*SigningV4Test) GetClientEndpoint

func (x *SigningV4Test) GetClientEndpoint() string

func (*SigningV4Test) GetDescription

func (x *SigningV4Test) GetDescription() string

func (*SigningV4Test) GetEmulatorHostname

func (x *SigningV4Test) GetEmulatorHostname() string

func (*SigningV4Test) GetExpectedCanonicalRequest

func (x *SigningV4Test) GetExpectedCanonicalRequest() string

func (*SigningV4Test) GetExpectedStringToSign

func (x *SigningV4Test) GetExpectedStringToSign() string

func (*SigningV4Test) GetExpectedUrl

func (x *SigningV4Test) GetExpectedUrl() string

func (*SigningV4Test) GetExpiration

func (x *SigningV4Test) GetExpiration() int64

func (*SigningV4Test) GetFileName

func (x *SigningV4Test) GetFileName() string

func (*SigningV4Test) GetHeaders

func (x *SigningV4Test) GetHeaders() map[string]string

func (*SigningV4Test) GetHostname

func (x *SigningV4Test) GetHostname() string

func (*SigningV4Test) GetMethod

func (x *SigningV4Test) GetMethod() string

func (*SigningV4Test) GetObject

func (x *SigningV4Test) GetObject() string

func (*SigningV4Test) GetQueryParameters

func (x *SigningV4Test) GetQueryParameters() map[string]string

func (*SigningV4Test) GetScheme

func (x *SigningV4Test) GetScheme() string

func (*SigningV4Test) GetTimestamp

func (x *SigningV4Test) GetTimestamp() *timestamppb.Timestamp

func (*SigningV4Test) GetUniverseDomain

func (x *SigningV4Test) GetUniverseDomain() string

func (*SigningV4Test) GetUrlStyle

func (x *SigningV4Test) GetUrlStyle() UrlStyle

func (*SigningV4Test) ProtoMessage

func (*SigningV4Test) ProtoMessage()

func (*SigningV4Test) ProtoReflect

func (x *SigningV4Test) ProtoReflect() protoreflect.Message

func (*SigningV4Test) Reset

func (x *SigningV4Test) Reset()

func (*SigningV4Test) String

func (x *SigningV4Test) String() string

type TestFile

type TestFile struct {
	SigningV4Tests    []*SigningV4Test    `protobuf:"bytes,1,rep,name=signing_v4_tests,json=signingV4Tests,proto3" json:"signing_v4_tests,omitempty"`
	PostPolicyV4Tests []*PostPolicyV4Test `protobuf:"bytes,2,rep,name=post_policy_v4_tests,json=postPolicyV4Tests,proto3" json:"post_policy_v4_tests,omitempty"`
	RetryTests        []*RetryTest        `protobuf:"bytes,3,rep,name=retry_tests,json=retryTests,proto3" json:"retry_tests,omitempty"`
	// contains filtered or unexported fields
}

func (*TestFile) Descriptor

func (*TestFile) Descriptor() ([]byte, []int)

Deprecated: Use TestFile.ProtoReflect.Descriptor instead.

func (*TestFile) GetPostPolicyV4Tests

func (x *TestFile) GetPostPolicyV4Tests() []*PostPolicyV4Test

func (*TestFile) GetRetryTests

func (x *TestFile) GetRetryTests() []*RetryTest

func (*TestFile) GetSigningV4Tests

func (x *TestFile) GetSigningV4Tests() []*SigningV4Test

func (*TestFile) ProtoMessage

func (*TestFile) ProtoMessage()

func (*TestFile) ProtoReflect

func (x *TestFile) ProtoReflect() protoreflect.Message

func (*TestFile) Reset

func (x *TestFile) Reset()

func (*TestFile) String

func (x *TestFile) String() string

type UrlStyle

type UrlStyle int32
const (
	UrlStyle_PATH_STYLE            UrlStyle = 0
	UrlStyle_VIRTUAL_HOSTED_STYLE  UrlStyle = 1
	UrlStyle_BUCKET_BOUND_HOSTNAME UrlStyle = 2
)

func (UrlStyle) Descriptor

func (UrlStyle) Descriptor() protoreflect.EnumDescriptor

func (UrlStyle) Enum

func (x UrlStyle) Enum() *UrlStyle

func (UrlStyle) EnumDescriptor

func (UrlStyle) EnumDescriptor() ([]byte, []int)

Deprecated: Use UrlStyle.Descriptor instead.

func (UrlStyle) Number

func (x UrlStyle) Number() protoreflect.EnumNumber

func (UrlStyle) String

func (x UrlStyle) String() string

func (UrlStyle) Type

Source Files

test.pb.go

Version
v1.50.0 (latest)
Published
Jan 9, 2025
Platform
linux/amd64
Imports
5 packages
Last checked
40 minutes ago

Tools for package owners.