This repository was archived by the owner on Jun 5, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +3
-9
lines changed Expand file tree Collapse file tree 2 files changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -1275,9 +1275,7 @@ func TestClientRTOAgentErr(t *testing.T) {
1275
1275
connL , connR := net .Pipe ()
1276
1276
defer connL .Close ()
1277
1277
collector := new (manualCollector )
1278
- clock := callbackClock (func () time.Time {
1279
- return time .Now ()
1280
- })
1278
+ clock := callbackClock (time .Now )
1281
1279
agent := & manualAgent {}
1282
1280
attempt := 0
1283
1281
gotReads := make (chan struct {})
@@ -1341,9 +1339,7 @@ func TestClient_HandleProcessError(t *testing.T) {
1341
1339
connL , connR := net .Pipe ()
1342
1340
defer connL .Close ()
1343
1341
collector := new (manualCollector )
1344
- clock := callbackClock (func () time.Time {
1345
- return time .Now ()
1346
- })
1342
+ clock := callbackClock (time .Now )
1347
1343
agent := & manualAgent {}
1348
1344
gotWrites := make (chan struct {})
1349
1345
processCalled := make (chan struct {}, 1 )
Original file line number Diff line number Diff line change @@ -192,9 +192,7 @@ func TestMessage_ForEach(t *testing.T) {
192
192
m = newMessage ()
193
193
var realm Realm
194
194
testutil .ShouldNotAllocate (t , func () {
195
- if err := m .ForEach (AttrRealm , func (m * Message ) error {
196
- return realm .GetFrom (m )
197
- }); err != nil {
195
+ if err := m .ForEach (AttrRealm , realm .GetFrom ); err != nil {
198
196
t .Fatal (err )
199
197
}
200
198
})
You can’t perform that action at this time.
0 commit comments