Petr Horáček has uploaded a new change for review. Change subject: tests: net: use new veth_pair networkTestsOVS.py ......................................................................
tests: net: use new veth_pair networkTestsOVS.py We do not have Veth object anymore. Use nettestlib:veth_pair() and ipwrapper:addrAdd(), ipwrapper:linkSet() instead of it. Change-Id: I6b18747a7e92b8259d32f93f1afbdf1670c844de Signed-off-by: Petr Horáček <[email protected]> --- M tests/functional/networkTestsOVS.py 1 file changed, 10 insertions(+), 9 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/14/46914/1 diff --git a/tests/functional/networkTestsOVS.py b/tests/functional/networkTestsOVS.py index b26105d..f1cd40f 100644 --- a/tests/functional/networkTestsOVS.py +++ b/tests/functional/networkTestsOVS.py @@ -20,17 +20,18 @@ from nose.plugins.skip import SkipTest +from vdsm.ipwrapper import linkSet, addrAdd from vdsm.utils import RollbackContext from testlib import expandPermutations, permutations from testValidation import RequireVethMod +from nettestlib import veth_pair from networkTests import (setupModule, tearDownModule, NetworkTest, dummyIf, _get_source_route, dnsmasqDhcp, NETWORK_NAME, IP_ADDRESS, IP_MASK, IP_CIDR, IP_GATEWAY, IPv6_ADDRESS, IPv6_CIDR, VLAN_ID, NOCHK, SUCCESS) from utils import VdsProxy -import veth import dhcp # Make Pyflakes happy @@ -215,10 +216,10 @@ # NOTE: without default route # TODO: more asserts """ - with veth.pair() as (left, right): - veth.setIP(left, IP_ADDRESS, IP_CIDR) - veth.setIP(left, IPv6_ADDRESS, IPv6_CIDR, 6) - veth.setLinkUp(left) + with veth_pair() as (left, right): + addrAdd(left, IP_ADDRESS, IP_CIDR) + addrAdd(left, IPv6_ADDRESS, IPv6_CIDR, 6) + linkSet(left, ['up']) with dnsmasqDhcp(left): network = { NETWORK_NAME: {'nic': right, 'bootproto': 'dhcp', @@ -274,10 +275,10 @@ """ Copied from networkTests.py, source_route checking changed from device_name to BRIDGE_NAME. """ - with veth.pair() as (left, right): - veth.setIP(left, IP_ADDRESS, IP_CIDR) - veth.setIP(left, IPv6_ADDRESS, IPv6_CIDR, 6) - veth.setLinkUp(left) + with veth_pair() as (left, right): + addrAdd(left, IP_ADDRESS, IP_CIDR) + addrAdd(left, IPv6_ADDRESS, IPv6_CIDR, 6) + linkSet(left, ['up']) with dnsmasqDhcp(left): dhcpv4 = 4 in families dhcpv6 = 6 in families -- To view, visit https://gerrit.ovirt.org/46914 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I6b18747a7e92b8259d32f93f1afbdf1670c844de Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Petr Horáček <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
