add support for setting ssl version to use
[plcapi.git] / test / parse_args.php
index 39549ce..151d943 100644 (file)
@@ -9,8 +9,7 @@
  * @param string  HTTPSSURI
  * @param string  PROXY
  *
- * @version $Id$
- * @copyright (C) 2007-2009 G. Giunta
+ * @copyright (C) 2007-20013 G. Giunta
  * @license code licensed under the BSD License: http://phpxmlrpc.sourceforge.net/license.txt
  **/
 
@@ -35,7 +34,8 @@
                                $param = explode('=', $param);
                                if(count($param) > 1)
                                {
-                                       $$param[0]=$param[1];
+                                       $pname = $param[0];
+                                       $$pname = $param[1];
                                }
                        }
                }
        {
                $HTTPSURI = '/server.php';
        }
+       if(!isset($HTTPSIGNOREPEER))
+       {
+               $HTTPSIGNOREPEER = false;
+       }
+       if(!isset($HTTPSVERIFYHOST))
+       {
+               $HTTPSVERIFYHOST = 2;
+       }
+       if(!isset($SSLVERSION))
+       {
+               $SSLVERSION = 0;
+       }
        if(!isset($PROXY))
        {
                $PROXYSERVER = null;
                        $PROXYPORT = 8080;
                }
        }
+    // used to silence testsuite warnings about proxy code not being tested
+    if(!isset($NOPROXY))
+    {
+        $NOPROXY = false;
+    }
        if(!isset($URI))
        {
                // GUESTIMATE the url of local demo server