mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-04-29 16:58:34 +00:00
Add Fake DNS support (#309)
Co-authored-by: Xiaokang Wang <xiaokangwang@outlook.com> Co-authored-by: loyalsoldier <10487845+Loyalsoldier@users.noreply.github.com> Co-authored-by: kslr <kslrwang@gmail.com>
This commit is contained in:
parent
db32ce6fd9
commit
f50eff5ebb
43 changed files with 1351 additions and 301 deletions
|
@ -6,6 +6,7 @@ package mocks
|
|||
|
||||
import (
|
||||
gomock "github.com/golang/mock/gomock"
|
||||
dns "github.com/xtls/xray-core/features/dns"
|
||||
net "net"
|
||||
reflect "reflect"
|
||||
)
|
||||
|
@ -48,18 +49,18 @@ func (mr *DNSClientMockRecorder) Close() *gomock.Call {
|
|||
}
|
||||
|
||||
// LookupIP mocks base method
|
||||
func (m *DNSClient) LookupIP(arg0 string) ([]net.IP, error) {
|
||||
func (m *DNSClient) LookupIP(arg0 string, arg1 dns.IPOption) ([]net.IP, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "LookupIP", arg0)
|
||||
ret := m.ctrl.Call(m, "LookupIP", arg0, arg1)
|
||||
ret0, _ := ret[0].([]net.IP)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// LookupIP indicates an expected call of LookupIP
|
||||
func (mr *DNSClientMockRecorder) LookupIP(arg0 interface{}) *gomock.Call {
|
||||
func (mr *DNSClientMockRecorder) LookupIP(arg0, arg1 interface{}) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LookupIP", reflect.TypeOf((*DNSClient)(nil).LookupIP), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LookupIP", reflect.TypeOf((*DNSClient)(nil).LookupIP), arg0, arg1)
|
||||
}
|
||||
|
||||
// Start mocks base method
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue