juju: github.com/wallyworld/juju/worker/raft/rafttest Index | Files

package rafttest

import "github.com/wallyworld/juju/worker/raft/rafttest"


Package Files

fixtures.go helpers.go

func CheckConfiguration Uses

func CheckConfiguration(c *gc.C, r *raft.Raft, expectedServers []raft.Server)

CheckConfiguration waits some time for the Raft to have the expected server configuration.

type RaftFixture Uses

type RaftFixture struct {

    FSM           raft.FSM
    Config        *raft.Config
    Transport     *raft.InmemTransport
    Store         *raft.InmemStore
    SnapshotStore *raft.InmemSnapshotStore
    Raft          *raft.Raft

RaftFixture is a fixture to embed into test suites, providing a raft.Raft and in-memory transport.

func (*RaftFixture) DefaultConfig Uses

func (s *RaftFixture) DefaultConfig(id raft.ServerID) *raft.Config

func (*RaftFixture) NewRaft Uses

func (s *RaftFixture) NewRaft(c *gc.C, id raft.ServerID, fsm raft.FSM) (

func (*RaftFixture) SetUpTest Uses

func (s *RaftFixture) SetUpTest(c *gc.C)

Package rafttest imports 10 packages (graph). Updated 2018-07-05. Refresh now. Tools for package owners. This is an inactive package (no imports and no commits in at least two years).