worker_test.go 210 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14
package worker

import "testing"

func TestStartClose(t *testing.T) {
	numRuns := 50
	if testing.Short() {
		numRuns = 5
	}
	for i := 0; i < numRuns; i++ {
		w := NewWorker(nil, DefaultConfig)
		w.Close()
	}
}