simplify naming

This commit is contained in:
Arpad Ryszka 2018-03-18 22:55:10 +01:00
parent ad44d95369
commit 77621be843
2 changed files with 4 additions and 4 deletions

View File

@ -195,10 +195,10 @@ func (b *SyncBus) ResetSignals(keys ...string) {
b.reset <- keys b.reset <- keys
} }
// ResetAllSignals clears all the set signals. // Reset clears all the signals.
// //
// If the receiver *SyncBus is nil, it is a noop. // If the receiver *SyncBus is nil, it is a noop.
func (b *SyncBus) ResetAllSignals() { func (b *SyncBus) Reset() {
if b == nil { if b == nil {
return return
} }

View File

@ -98,7 +98,7 @@ func TestNilResetAll(t *testing.T) {
tw.done() tw.done()
}() }()
bus.ResetAllSignals() bus.Reset()
if err := tw.wait(); err != nil { if err := tw.wait(); err != nil {
t.Error(err) t.Error(err)
} }
@ -284,7 +284,7 @@ func TestResetAll(t *testing.T) {
bus.Signal("bar") bus.Signal("bar")
bus.Signal("baz") bus.Signal("baz")
bus.ResetAllSignals() bus.Reset()
if err := bus.Wait("foo", "bar", "baz"); err != ErrTimeout { if err := bus.Wait("foo", "bar", "baz"); err != ErrTimeout {
t.Error("failed to timeout") t.Error("failed to timeout")
} }