streamdeck-obs-replay/replay_test.go

22 lines
414 B
Go
Raw Normal View History

2020-01-15 04:32:53 +00:00
package main
import (
"meow.tf/streamdeck/obs-replay/obsws"
"testing"
)
func Test_ReplayStatus(t *testing.T) {
c := &obsws.Client{Host: "localhost", Port: 4444}
if err := c.Connect(); err != nil {
t.Fatal(err)
}
c.AddEventHandler("StreamStatus", func(e obsws.Event) {
// Make sure to assert the actual event type.
t.Log("status:", e.(obsws.StreamStatusEvent).Replay)
})
<- make(chan struct{})
}