summaryrefslogtreecommitdiff
path: root/repeat_test.go
diff options
context:
space:
mode:
authormo khan <mo.khan@gmail.com>2019-10-23 20:11:29 -0600
committermo khan <mo.khan@gmail.com>2019-10-23 20:11:29 -0600
commitd87ddbb288b7407179285c0f5193b3272027eea6 (patch)
treec659940475e3954252b66fad31aec1c153e7aa37 /repeat_test.go
parentda86ef8bd27327bf019e65751a827744e3a46a6e (diff)
Add times parameter
Diffstat (limited to 'repeat_test.go')
-rw-r--r--repeat_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/repeat_test.go b/repeat_test.go
index 4cfe358..ccb8d12 100644
--- a/repeat_test.go
+++ b/repeat_test.go
@@ -4,7 +4,7 @@ import "testing"
func TestRepeat(t *testing.T) {
t.Run("default", func(t *testing.T) {
- repeated := Repeat("a")
+ repeated := Repeat("a", 5)
expected := "aaaaa"
if repeated != expected {
@@ -24,6 +24,6 @@ func TestRepeat(t *testing.T) {
func BenchmarkRepeat(b *testing.B) {
for i := 0; i < b.N; i++ {
- Repeat("a")
+ Repeat("a", 5)
}
}