@@ -109,20 +109,23 @@ func TestAgentActiveTCP(t *testing.T) {
109
109
110
110
r .NotNil (tcpMux .LocalAddr (), "tcpMux.LocalAddr() is nil" )
111
111
112
+ hostAcceptanceMinWait := 100 * time .Millisecond
112
113
passiveAgent , err := NewAgent (& AgentConfig {
113
- TCPMux : tcpMux ,
114
- CandidateTypes : []CandidateType {CandidateTypeHost },
115
- NetworkTypes : testCase .networkTypes ,
116
- LoggerFactory : loggerFactory ,
117
- IncludeLoopback : true ,
114
+ TCPMux : tcpMux ,
115
+ CandidateTypes : []CandidateType {CandidateTypeHost },
116
+ NetworkTypes : testCase .networkTypes ,
117
+ LoggerFactory : loggerFactory ,
118
+ IncludeLoopback : true ,
119
+ HostAcceptanceMinWait : & hostAcceptanceMinWait ,
118
120
})
119
121
r .NoError (err )
120
122
r .NotNil (passiveAgent )
121
123
122
124
activeAgent , err := NewAgent (& AgentConfig {
123
- CandidateTypes : []CandidateType {CandidateTypeHost },
124
- NetworkTypes : testCase .networkTypes ,
125
- LoggerFactory : loggerFactory ,
125
+ CandidateTypes : []CandidateType {CandidateTypeHost },
126
+ NetworkTypes : testCase .networkTypes ,
127
+ LoggerFactory : loggerFactory ,
128
+ HostAcceptanceMinWait : & hostAcceptanceMinWait ,
126
129
})
127
130
r .NoError (err )
128
131
r .NotNil (activeAgent )
0 commit comments