You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: bernoulli_test.go
    path of file: ./repos/gonum/stat/distuv
    
    the code of the file until where you have to start completion: // Copyright Â©2016 The Gonum Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package distuv

import (
	"math"
	"sort"
	"testing"

	"golang.org/x/exp/rand"
)

func TestBernoulli(t *testing.T) {
    
func testBernoulliSurvival(t *testing.T, dist Bernoulli) {
	if dist.Survival(-0.000001) != 1 {
		t.Errorf("Bernoulli Survival below zero is not one")
	}
	if dist.Survival(0) != dist.P {
		t.Errorf("Bernoulli Survival at zero is not P(1)")
	}
	if dist.Survival(0.0001) != dist.P {
		t.Errorf("Bernoulli Survival between zero and one is not P(1)")
	}
	if dist.Survival(1) != 0 {
		t.Errorf("Bernoulli Survival at one is not zero")
	}
	if dist.Survival(1.00001) != 0 {
		t.Errorf("Bernoulli Survival above one is not zero")
	}
}