mirror of
https://github.com/buger/goreplay.git
synced 2024-04-21 12:32:02 +00:00
Fix test.
This commit is contained in:
+1
-1
@@ -22,7 +22,7 @@ type Middleware struct {
|
||||
Stdin io.Writer
|
||||
Stdout io.Reader
|
||||
|
||||
stop chan bool // Channel used only to indicate goroutine should shutdown
|
||||
stop chan bool // Channel used only to indicate goroutine should shutdown
|
||||
}
|
||||
|
||||
func NewMiddleware(command string) *Middleware {
|
||||
|
||||
+5
-2
@@ -49,11 +49,14 @@ func TestFileOutput(t *testing.T) {
|
||||
Inputs: []io.Reader{input2},
|
||||
Outputs: []io.Writer{output2},
|
||||
}
|
||||
plugins2.All = append(plugins2.All, input2, output2)
|
||||
|
||||
go emitter.Start(plugins2, Settings.middleware)
|
||||
quit2 := make(chan int)
|
||||
emitter2 := NewEmitter(quit2)
|
||||
go emitter2.Start(plugins2, Settings.middleware)
|
||||
|
||||
wg.Wait()
|
||||
emitter.Close()
|
||||
emitter2.Close()
|
||||
}
|
||||
|
||||
func TestFileOutputWithNameCleaning(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user