Skip to content

Commit

Permalink
Add test for second invocation of self evict
Browse files Browse the repository at this point in the history
  • Loading branch information
Nils Dijk committed Aug 23, 2016
1 parent 8b2ec0c commit 9d8126a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions swim/self_evict_test.go
Expand Up @@ -119,7 +119,13 @@ func (s *SelfEvictTestSuite) TestSelfEvict_SelfEvict_GossipFaulty() {

peerView, _ = s.peer.memberlist.Member(address)
s.Assert().Equal(Faulty, peerView.Status, "expected to be seen as faulty by a peer after self eviction")
}

func (s *SelfEvictTestSuite) TestSelfEvict_SelfEvict_AlreadyRunning() {
err := s.node.SelfEvict()
s.Assert().NoError(err, "expected no error during self eviction")
err = s.node.SelfEvict()
s.Assert().Error(err, "expected an error when self evict is called for the second time.")
}

func TestSelfEvictTestSuite(t *testing.T) {
Expand Down

0 comments on commit 9d8126a

Please sign in to comment.