github.com/MontFerret/ferret@v0.18.0/pkg/stdlib/math/rand_test.go (about) 1 package math_test 2 3 import ( 4 "context" 5 "testing" 6 7 . "github.com/smartystreets/goconvey/convey" 8 9 "github.com/MontFerret/ferret/pkg/stdlib/math" 10 ) 11 12 func TestRand(t *testing.T) { 13 Convey("Should return pseudo-random value", t, func() { 14 out, err := math.Rand(context.Background()) 15 16 So(err, ShouldBeNil) 17 So(out, ShouldBeLessThan, 1) 18 }) 19 }