[node-patches] Change in ovirt-node[master]: network: Remove node_nics() doctest

fabiand at fedoraproject.org fabiand at fedoraproject.org
Fri May 31 12:00:51 UTC 2013


Fabian Deutsch has uploaded a new change for review.

Change subject: network: Remove node_nics() doctest
......................................................................

network: Remove node_nics() doctest

Because it is relying on runtime informations.

Change-Id: I609f64ba3ca640d20d08aabe26005b365b8191fb
Signed-off-by: Fabian Deutsch <fabiand at fedoraproject.org>
---
M src/Makefile.check
M src/ovirt/node/utils/network.py
2 files changed, 3 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/56/15256/1

diff --git a/src/Makefile.check b/src/Makefile.check
index 9bd2254..a90af48 100644
--- a/src/Makefile.check
+++ b/src/Makefile.check
@@ -17,7 +17,9 @@
 	@echo Passed $@
 
 %.doctest:
-	PYTHONPATH=. python -m doctest "$*"
+# A naive check to see if there is a doctest in the file
+# To save some CPU cycles
+	{ grep -qs ">>>" "$*" && PYTHONPATH=. python -m doctest "$*" ; true ; }
 
 check-static-pep8: $(PYTHONSOURCES:%=%.pep8)
 	@echo Passed $@
diff --git a/src/ovirt/node/utils/network.py b/src/ovirt/node/utils/network.py
index 3336f13..2b417e5 100644
--- a/src/ovirt/node/utils/network.py
+++ b/src/ovirt/node/utils/network.py
@@ -225,9 +225,6 @@
     If a NIC is configured, merge the info+cfg of the bridge into the slave.
     If the slave is a vlan NIC set the vlanidof the parent device according to
     this vlan NICs id.
-
-    >>> node_nics() != None
-    True
     """
     all_ifaces = relevant_ifaces(filter_bridges=False, filter_vlans=False)
     all_infos = dict((i, iface_information(i)) for i in all_ifaces)


--
To view, visit http://gerrit.ovirt.org/15256
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I609f64ba3ca640d20d08aabe26005b365b8191fb
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Fabian Deutsch <fabiand at fedoraproject.org>



More information about the node-patches mailing list