Added legacy network adapter driver mock up.
This commit is contained in:
parent
da8b140bca
commit
31d03fb48e
|
@ -66,6 +66,11 @@ type DriverMock struct {
|
|||
GetVirtualMachineNetworkAdapterAddress_Return string
|
||||
GetVirtualMachineNetworkAdapterAddress_Err error
|
||||
|
||||
ReplaceVirtualMachineNetworkAdapter_Called bool
|
||||
ReplaceVirtualMachineNetworkAdapter_VmName string
|
||||
ReplaceVirtualMachineNetworkAdapter_Replace bool
|
||||
ReplaceVirtualMachineNetworkAdapter_Err error
|
||||
|
||||
SetNetworkAdapterVlanId_Called bool
|
||||
SetNetworkAdapterVlanId_SwitchName string
|
||||
SetNetworkAdapterVlanId_VlanId string
|
||||
|
@ -335,6 +340,13 @@ func (d *DriverMock) GetVirtualMachineNetworkAdapterAddress(vmName string) (stri
|
|||
return d.GetVirtualMachineNetworkAdapterAddress_Return, d.GetVirtualMachineNetworkAdapterAddress_Err
|
||||
}
|
||||
|
||||
func (d *DriverMock) ReplaceVirtualMachineNetworkAdapter(vmName string, replace bool) error {
|
||||
d.ReplaceVirtualMachineNetworkAdapter_Called = true
|
||||
d.ReplaceVirtualMachineNetworkAdapter_VmName = vmName
|
||||
d.ReplaceVirtualMachineNetworkAdapter_Replace = vmName
|
||||
return d.ReplaceVirtualMachineNetworkAdapter_Err
|
||||
}
|
||||
|
||||
func (d *DriverMock) SetNetworkAdapterVlanId(switchName string, vlanId string) error {
|
||||
d.SetNetworkAdapterVlanId_Called = true
|
||||
d.SetNetworkAdapterVlanId_SwitchName = switchName
|
||||
|
|
Loading…
Reference in New Issue