client/rhel/rhnlib/test/24-ssl-memleak.py | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
New commits:
commit 85b34266a1d15b3d003c04845485ee14b4ab0a50
Author: Simon Lukasik <slukasik(a)redhat.com>
Date: Thu Apr 8 12:46:19 2010 +0200
Added support for cmd-line arguments
diff --git a/client/rhel/rhnlib/test/24-ssl-memleak.py
b/client/rhel/rhnlib/test/24-ssl-memleak.py
old mode 100644
new mode 100755
index 7d62ca0..387c740
--- a/client/rhel/rhnlib/test/24-ssl-memleak.py
+++ b/client/rhel/rhnlib/test/24-ssl-memleak.py
@@ -1,6 +1,8 @@
#!/usr/bin/python
#
# $Id$
+#
+# USAGE: $0 SERVER CERT
"""
Tests a memory leak in the applet
"""
@@ -10,8 +12,14 @@ import string
from rhn import rpclib
def main():
- server_url = "https://xmlrpc.rhn.webqa.redhat.com/APPLET"
+ server_name = "xmlrpc.rhn.redhat.com"
ca_cert = "/usr/share/rhn/RHNS-CA-CERT"
+ try:
+ server_name = sys.argv[1]
+ ca_cert = sys.argv[2]
+ except:
+ pass
+ server_url = "https://" + server_name + "/APPLET"
diff_count = 0
mem_usage = None
Show replies by date