KVM test: Fixing kvm release tag detection
The recent sourceforge facelift/changes broke our ability to determine
KVM release tags. This patch fixes up things.
Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
git-svn-id: http://test.kernel.org/svn/autotest/trunk@3369 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/tests/kvm/kvm_utils.py b/client/tests/kvm/kvm_utils.py
index a37d322..b2b0d1a 100644
--- a/client/tests/kvm/kvm_utils.py
+++ b/client/tests/kvm/kvm_utils.py
@@ -139,13 +139,9 @@
f = open(local_web_page, "r")
data = f.read()
f.close()
- rx = re.compile("package_id=(\d+).*\>kvm\<", re.IGNORECASE)
+ rx = re.compile("kvm-(\d+).tar.gz", re.IGNORECASE)
matches = rx.findall(data)
package_id = matches[0]
- #package_id = 209008
- rx = re.compile("package_id=%s.*release_id=\d+\">(\d+)" % package_id,
- re.IGNORECASE)
- matches = rx.findall(data)
return matches[0] # the first match contains the latest release tag
except Exception, e:
message = "Could not fetch latest KVM release tag: %s" % str(e)