Commit f2d3cc2d by Victor Shnayder

fix argument quoting

parent 5ef67d47
...@@ -6,7 +6,8 @@ A script to run some ab load tests. ...@@ -6,7 +6,8 @@ A script to run some ab load tests.
import os import os
import sys import sys
import argparse import argparse
import subprocess
import pipes
""" """
...@@ -59,11 +60,11 @@ def test_url(url, requests, concurrency, ab_options, logpath): ...@@ -59,11 +60,11 @@ def test_url(url, requests, concurrency, ab_options, logpath):
cmd = "ab -n {requests} -c {concurrency} {opts} {url} | tee -- {log}".format(requests=requests, cmd = "ab -n {requests} -c {concurrency} {opts} {url} | tee -- {log}".format(requests=requests,
concurrency=concurrency, concurrency=concurrency,
url=url, url=pipes.quote(url),
opts=ab_options, opts=ab_options,
log=logpath,) log=pipes.quote(logpath),)
print "running {0}".format(cmd) print "running {0}".format(cmd)
os.system(cmd) subprocess.call(cmd, shell=True)
def read_pagelist(filepath): def read_pagelist(filepath):
""" """
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment