// Code generated by "./generator ./system/org.deepin.dde.ipwatchd1"; DO NOT EDIT.

// SPDX-FileCopyrightText: 2018 - 2023 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later
package ipwatchd1

import (
	"fmt"

	"github.com/godbus/dbus/v5"
	"github.com/linuxdeepin/go-lib/dbusutil"
	"github.com/linuxdeepin/go-lib/dbusutil/proxy"
	"github.com/stretchr/testify/mock"
)

type MockIPWatchD struct {
	MockInterfaceIpwatchd // interface org.deepin.dde.IPWatchD1
	proxy.MockObject
}

type MockInterfaceIpwatchd struct {
	mock.Mock
}

// method RequestIPConflictCheck

func (v *MockInterfaceIpwatchd) GoRequestIPConflictCheck(flags dbus.Flags, ch chan *dbus.Call, ip string, ifc string) *dbus.Call {
	mockArgs := v.Called(flags, ch, ip, ifc)

	ret, ok := mockArgs.Get(0).(*dbus.Call)
	if !ok {
		panic(fmt.Sprintf("assert: arguments: 0 failed because object wasn't correct type: %v", mockArgs.Get(0)))
	}

	return ret
}

func (v *MockInterfaceIpwatchd) RequestIPConflictCheck(flags dbus.Flags, ip string, ifc string) (string, error) {
	mockArgs := v.Called(flags, ip, ifc)

	return mockArgs.String(0), mockArgs.Error(1)
}

// signal IPConflict

func (v *MockInterfaceIpwatchd) ConnectIPConflict(cb func(ip string, smac string, dmac string)) (dbusutil.SignalHandlerId, error) {
	mockArgs := v.Called(cb)

	ret0, ok := mockArgs.Get(0).(dbusutil.SignalHandlerId)
	if !ok {
		panic(fmt.Sprintf("assert: arguments: %d failed because object wasn't correct type: %v", 0, mockArgs.Get(0)))
	}

	return ret0, mockArgs.Error(1)
}
