Documentation ¶
Overview ¶
Package startstop provides a test fixture to make sure some conditions around ARC starting and ARC stopping for performance and stability by reducing the number of Chrome launching.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Subtest ¶
type Subtest interface { // Name returns the name of this subtest. Name() string // PreStart is called before starting Chrome. PreStart(ctx context.Context, s *testing.State) // PostStart is called after starting ARC, i.e. called during the // ARC session. PostStart(ctx context.Context, s *testing.State) // PostStop is called after logout from Chrome. PostStop(ctx context.Context, s *testing.State) }
Subtest defines a test runs in arc.StartStop. Each implementation of Subtest can use the following methods to check some conditions, or to record some values to be used in a method called later. Even if an error is reported in a method, another method will be called unless the arc.StartStop is not terminated. For example, even if s.Error() is called in PostStart(), PostStop() for the same Subtest instance may be called later. The invocation of PreStart, PostStart and PostStop is wrapped by testing.State.Run, so even if s.Fatal() or s.Fatalf() is called, other methods will be called, still.
type TestMidis ¶
type TestMidis struct{}
TestMidis verifies midis daemon starts correctly.
type TestMount ¶
type TestMount struct{}
TestMount runs inside arc.StartStop.
type TestPID ¶
type TestPID struct {
// contains filtered or unexported fields
}
TestPID runs inside arc.StartStop.
func (*TestPID) PostStart ¶
PostStart implements Subtest.PostStart(). It remembers the current ARC's init PID, which is used in PostStop().