<s> from pyresttest import resttest <EOL> from pyresttest . benchmarks import Benchmark <EOL> from pyresttest . binding import Context <EOL> from pyresttest . contenthandling import ContentHandler <EOL> from pyresttest . generators import factory_generate_ids <EOL> import cProfile <EOL> test = Benchmark ( ) <EOL> test . warmup_runs = <NUM_LIT:0> <EOL> test . benchmark_runs = <NUM_LIT:1000> <EOL> test . raw_metrics = set ( ) <EOL> test . metrics = { '<STR_LIT>' } <EOL> test . aggregated_metrics = { '<STR_LIT>' : [ '<STR_LIT>' , '<STR_LIT>' ] } <EOL> test . url = '<STR_LIT>' <EOL> test . name = '<STR_LIT>' <EOL> print '<STR_LIT>' <EOL> test . method = '<STR_LIT>' <EOL> test . set_url ( '<STR_LIT>' , isTemplate = True ) <EOL> test . headers = { '<STR_LIT:Content-Type>' : '<STR_LIT:application/json>' } <EOL> handler = ContentHandler ( ) <EOL> handler . setup ( '<STR_LIT>' , <EOL> is_template_content = True ) <EOL> test . body = handler <EOL> context = Context ( ) <EOL> context . add_generator ( '<STR_LIT>' , factory_generate_ids ( starting_id = <NUM_LIT:10> ) ( ) ) <EOL> test . generator_binds = { '<STR_LIT:id>' : '<STR_LIT>' } <EOL> print '<STR_LIT>' <EOL> cProfile . run ( '<STR_LIT>' , sort = '<STR_LIT>' ) </s>
