Documentation
¶
Overview ¶
Package integration exports a set of unit tests that can be run by impl/integration or any other specific instantiation of KeyTransparency.
Index ¶
- Variables
- func TestBatchCreate(ctx context.Context, env *Env, t *testing.T)
- func TestBatchUpdate(ctx context.Context, env *Env, t *testing.T)
- func TestEmptyGetAndUpdate(ctx context.Context, env *Env, t *testing.T)
- func TestListHistory(ctx context.Context, env *Env, t *testing.T)
- func TestMonitor(ctx context.Context, env *Env, t *testing.T)
- type CallOptions
- type Env
- type NamedTestFn
Constants ¶
This section is empty.
Variables ¶
var AllTests = []NamedTestFn{ {Name: "TestEmptyGetAndUpdate", Fn: TestEmptyGetAndUpdate}, {Name: "TestListHistory", Fn: TestListHistory}, {Name: "TestBatchUpdate", Fn: TestBatchUpdate}, {Name: "TestBatchCreate", Fn: TestBatchCreate}, {Name: "TestMonitor", Fn: TestMonitor}, }
AllTests contains all the integration tests. Be sure to extend this when additional tests are added. This is done so that tests can be run in different environments in a portable way.
Functions ¶
func TestBatchCreate ¶
TestBatchCreate verifies that the batch functions are working correctly.
func TestBatchUpdate ¶
TestBatchUpdate verifies that the batch functions are working correctly.
func TestEmptyGetAndUpdate ¶
TestEmptyGetAndUpdate verifies set/get semantics.
func TestListHistory ¶
TestListHistory verifies that repeated history values get collapsed properly.
Types ¶
type CallOptions ¶
type CallOptions func(userID string) []grpc.CallOption
CallOptions returns grpc.CallOptions for the requested user.
type Env ¶
type Env struct { Client *client.Client Cli pb.KeyTransparencyClient Sequencer spb.KeyTransparencySequencerClient Directory *pb.Directory Timeout time.Duration CallOpts CallOptions }
Env holds a complete testing environment for end-to-end tests.