Skip to content

Commit

Permalink
Remove leftover code
Browse files Browse the repository at this point in the history
  • Loading branch information
Henrique Santos committed Oct 26, 2023
1 parent ead8de5 commit d8edc3c
Showing 1 changed file with 0 additions and 116 deletions.
116 changes: 0 additions & 116 deletions core/wait/wait_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,35 +67,6 @@ func TestSetThrottle(t *testing.T) {
}
})
}

f := &AsyncActionHandler[interface{}]{
throttle: 1 * time.Minute,
}

type fields struct {
throttle time.Duration
}
type args struct {
d time.Duration
}
tests := []struct {
name string
fields fields
args args
want *AsyncActionHandler[interface{}]
}{
{"ok", fields{throttle: 30 * time.Second}, args{d: 1 * time.Minute}, f},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
w := &AsyncActionHandler[interface{}]{
throttle: tt.fields.throttle,
}
if got := w.SetThrottle(tt.args.d); !cmp.Equal(got, tt.want, cmp.AllowUnexported(AsyncActionHandler[interface{}]{})) {
t.Errorf("Wait.SetThrottle() = %v, want %v", got, tt.want)
}
})
}
}

func TestSetTimeout(t *testing.T) {
Expand Down Expand Up @@ -130,35 +101,6 @@ func TestSetTimeout(t *testing.T) {
}
})
}

f := &AsyncActionHandler[interface{}]{
throttle: 1 * time.Minute,
}

type fields struct {
throttle time.Duration
}
type args struct {
d time.Duration
}
tests := []struct {
name string
fields fields
args args
want *AsyncActionHandler[interface{}]
}{
{"ok", fields{throttle: 30 * time.Second}, args{d: 1 * time.Minute}, f},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
w := &AsyncActionHandler[interface{}]{
throttle: tt.fields.throttle,
}
if got := w.SetThrottle(tt.args.d); !cmp.Equal(got, tt.want, cmp.AllowUnexported(AsyncActionHandler[interface{}]{})) {
t.Errorf("Wait.SetThrottle() = %v, want %v", got, tt.want)
}
})
}
}

func TestSetSleepBeforeWait(t *testing.T) {
Expand Down Expand Up @@ -193,35 +135,6 @@ func TestSetSleepBeforeWait(t *testing.T) {
}
})
}

f := &AsyncActionHandler[interface{}]{
throttle: 1 * time.Minute,
}

type fields struct {
throttle time.Duration
}
type args struct {
d time.Duration
}
tests := []struct {
name string
fields fields
args args
want *AsyncActionHandler[interface{}]
}{
{"ok", fields{throttle: 30 * time.Second}, args{d: 1 * time.Minute}, f},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
w := &AsyncActionHandler[interface{}]{
throttle: tt.fields.throttle,
}
if got := w.SetThrottle(tt.args.d); !cmp.Equal(got, tt.want, cmp.AllowUnexported(AsyncActionHandler[interface{}]{})) {
t.Errorf("Wait.SetThrottle() = %v, want %v", got, tt.want)
}
})
}
}

func TestSetTempErrRetryLimit(t *testing.T) {
Expand Down Expand Up @@ -252,35 +165,6 @@ func TestSetTempErrRetryLimit(t *testing.T) {
}
})
}

f := &AsyncActionHandler[interface{}]{
throttle: 1 * time.Minute,
}

type fields struct {
throttle time.Duration
}
type args struct {
d time.Duration
}
tests := []struct {
name string
fields fields
args args
want *AsyncActionHandler[interface{}]
}{
{"ok", fields{throttle: 30 * time.Second}, args{d: 1 * time.Minute}, f},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
w := &AsyncActionHandler[interface{}]{
throttle: tt.fields.throttle,
}
if got := w.SetThrottle(tt.args.d); !cmp.Equal(got, tt.want, cmp.AllowUnexported(AsyncActionHandler[interface{}]{})) {
t.Errorf("Wait.SetThrottle() = %v, want %v", got, tt.want)
}
})
}
}

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

0 comments on commit d8edc3c

Please sign in to comment.