| tierno | f8fa9f0 | 2016-12-28 09:11:15 +0100 | [diff] [blame] | 1 | #!/usr/bin/env python2 |
| 2 | # -*- coding: utf-8 -*- |
| 3 | |
| 4 | ## |
| tierno | 9202102 | 2018-09-12 16:29:23 +0200 | [diff] [blame] | 5 | # Copyright 2015 Telefonica Investigacion y Desarrollo, S.A.U. |
| tierno | f8fa9f0 | 2016-12-28 09:11:15 +0100 | [diff] [blame] | 6 | # This file is part of openmano |
| 7 | # All Rights Reserved. |
| 8 | # |
| 9 | # Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 10 | # not use this file except in compliance with the License. You may obtain |
| 11 | # a copy of the License at |
| 12 | # |
| 13 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 14 | # |
| 15 | # Unless required by applicable law or agreed to in writing, software |
| 16 | # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
| 17 | # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
| 18 | # License for the specific language governing permissions and limitations |
| 19 | # under the License. |
| 20 | # |
| 21 | # For those usages not covered by the Apache License, Version 2.0 please |
| 22 | # contact with: nfvlabs@tid.es |
| 23 | ## |
| 24 | |
| 25 | ''' |
| 26 | Module to test openmanoclient class and indirectly the whole openmano |
| 27 | It allows both python 2 and python 3 |
| 28 | ''' |
| 29 | __author__="Alfonso Tierno" |
| 30 | __date__ ="$09-Mar-2016 09:09:48$" |
| 31 | __version__="0.0.2" |
| 32 | version_date="May 2016" |
| 33 | |
| 34 | import logging |
| 35 | import imp |
| 36 | |
| 37 | |
| 38 | |
| 39 | def _get_random_name(maxLength): |
| 40 | '''generates a string with random craracters from space (ASCCI 32) to ~(ASCCI 126) |
| 41 | with a random length up to maxLength |
| 42 | ''' |
| 43 | long_name = "testing up to {} size name: ".format(maxLength) |
| 44 | #long_name += ''.join(chr(random.randint(32,126)) for _ in range(random.randint(20, maxLength-len(long_name)))) |
| 45 | long_name += ''.join(random.choice('abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ') for _ in range(20, maxLength-len(long_name))) |
| 46 | return long_name |
| 47 | |
| 48 | |
| 49 | if __name__=="__main__": |
| 50 | import getopt |
| 51 | #import os |
| 52 | import sys |
| 53 | |
| 54 | |
| 55 | |
| 56 | usage =\ |
| 57 | """Make a test against an openmano server.\nUsage: test_openmanoclient [options] |
| 58 | -v|--verbose: prints more info in the test |
| 59 | --version: shows current version |
| 60 | -h|--help: shows this help |
| 61 | -d|--debug: set logs to debug level |
| 62 | -t|--tenant: set the tenant name to test. By default creates one |
| 63 | --datacenter: set the datacenter name to test. By default creates one at http://localhost:9080/openvim |
| 64 | -u|--url: set the openmano server url. By default 'http://localhost:9090/openmano' |
| 65 | --image: use this image path for testing a VNF. By default a fake one is generated, valid for VIM in test mode' |
| 66 | """ |
| 67 | |
| 68 | #import openmanoclient from relative path |
| 69 | module_info = imp.find_module("openmanoclient", [".."] ) |
| 70 | Client = imp.load_module("Client", *module_info) |
| 71 | |
| 72 | streamformat = "%(asctime)s %(name)s %(levelname)s: %(message)s" |
| 73 | logging.basicConfig(format=streamformat) |
| 74 | try: |
| 75 | opts, args = getopt.getopt(sys.argv[1:], "t:u:dhv", ["url=", "tenant=", "debug", "help", "version", "verbose", "datacenter=", "image="]) |
| 76 | except getopt.GetoptError as err: |
| 77 | print ("Error: {}\n Try '{} --help' for more information".format(str(err), sys.argv[0])) |
| 78 | sys.exit(2) |
| 79 | |
| 80 | debug = False |
| 81 | verbose = False |
| 82 | url = "http://localhost:9090/openmano" |
| 83 | to_delete_list=[] |
| 84 | test_tenant = None |
| 85 | test_datacenter = None |
| 86 | test_vim_tenant = None |
| 87 | test_image = None |
| 88 | for o, a in opts: |
| 89 | if o in ("-v", "--verbose"): |
| 90 | verbose = True |
| 91 | elif o in ("--version"): |
| 92 | print ("{} version".format(sys.argv[0]), __version__, version_date) |
| 93 | print ("(c) Copyright Telefonica") |
| 94 | sys.exit() |
| 95 | elif o in ("-h", "--help"): |
| 96 | print(usage) |
| 97 | sys.exit() |
| 98 | elif o in ("-d", "--debug"): |
| 99 | debug = True |
| 100 | elif o in ("-u", "--url"): |
| 101 | url = a |
| 102 | elif o in ("-t", "--tenant"): |
| 103 | test_tenant = a |
| 104 | elif o in ("--datacenter"): |
| 105 | test_datacenter = a |
| 106 | elif o in ("--image"): |
| 107 | test_image = a |
| 108 | else: |
| 109 | assert False, "Unhandled option" |
| 110 | |
| 111 | |
| 112 | |
| 113 | client = Client.openmanoclient( |
| 114 | endpoint_url=url, |
| 115 | tenant_name=test_tenant, |
| 116 | datacenter_name = test_datacenter, |
| 117 | debug = debug) |
| 118 | |
| 119 | import random |
| 120 | test_number=1 |
| 121 | |
| 122 | #TENANTS |
| 123 | print(" {}. TEST create_tenant".format(test_number)) |
| 124 | test_number += 1 |
| 125 | long_name = _get_random_name(60) |
| 126 | |
| 127 | tenant = client.create_tenant(name=long_name, description=long_name) |
| 128 | if verbose: print(tenant) |
| 129 | |
| 130 | print(" {}. TEST list_tenants".format(test_number)) |
| 131 | test_number += 1 |
| 132 | tenants = client.list_tenants() |
| 133 | if verbose: print(tenants) |
| 134 | |
| 135 | print(" {}. TEST list_tenans filter by name".format(test_number)) |
| 136 | test_number += 1 |
| 137 | tenants_ = client.list_tenants(name=long_name) |
| 138 | if not tenants_["tenants"]: |
| 139 | raise Exception("Text error, no TENANT found with name") |
| 140 | if verbose: print(tenants_) |
| 141 | |
| 142 | print(" {}. TEST get_tenant by UUID".format(test_number)) |
| 143 | test_number += 1 |
| 144 | tenant = client.get_tenant(uuid=tenants_["tenants"][0]["uuid"]) |
| 145 | if verbose: print(tenant) |
| 146 | |
| 147 | print(" {}. TEST delete_tenant by name".format(test_number)) |
| 148 | test_number += 1 |
| 149 | tenant = client.delete_tenant(name = long_name) |
| 150 | if verbose: print(tenant) |
| 151 | |
| 152 | if not test_tenant: |
| 153 | print(" {}. TEST create_tenant for remaining tests".format(test_number)) |
| 154 | test_number += 1 |
| 155 | test_tenant = "test-tenant "+\ |
| 156 | ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 157 | tenant = client.create_tenant(name = test_tenant) |
| 158 | if verbose: print(tenant) |
| 159 | client["tenant_name"] = test_tenant |
| 160 | |
| 161 | to_delete_list.insert(0,{"item": "tenant", "function": client.delete_tenant, "params":{"name": test_tenant} }) |
| 162 | |
| 163 | #DATACENTERS |
| 164 | print(" {}. TEST create_datacenter".format(test_number)) |
| 165 | test_number += 1 |
| 166 | long_name = _get_random_name(60) |
| 167 | |
| 168 | datacenter = client.create_datacenter(name=long_name, vim_url="http://fakeurl/fake") |
| 169 | if verbose: print(datacenter) |
| 170 | |
| 171 | print(" {}. TEST list_datacenters".format(test_number)) |
| 172 | test_number += 1 |
| 173 | datacenters = client.list_datacenters(all_tenants=True) |
| 174 | if verbose: print(datacenters) |
| 175 | |
| 176 | print(" {}. TEST list_tenans filter by name".format(test_number)) |
| 177 | test_number += 1 |
| 178 | datacenters_ = client.list_datacenters(all_tenants=True, name=long_name) |
| 179 | if not datacenters_["datacenters"]: |
| 180 | raise Exception("Text error, no TENANT found with name") |
| 181 | if verbose: print(datacenters_) |
| 182 | |
| 183 | print(" {}. TEST get_datacenter by UUID".format(test_number)) |
| 184 | test_number += 1 |
| 185 | datacenter = client.get_datacenter(uuid=datacenters_["datacenters"][0]["uuid"], all_tenants=True) |
| 186 | if verbose: print(datacenter) |
| 187 | |
| 188 | print(" {}. TEST delete_datacenter by name".format(test_number)) |
| 189 | test_number += 1 |
| 190 | datacenter = client.delete_datacenter(name=long_name) |
| 191 | if verbose: print(datacenter) |
| 192 | |
| 193 | if not test_datacenter: |
| 194 | print(" {}. TEST create_datacenter for remaining tests".format(test_number)) |
| 195 | test_number += 1 |
| 196 | test_datacenter = "test-datacenter "+\ |
| 197 | ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 198 | datacenter = client.create_datacenter(name=test_datacenter, vim_url="http://127.0.0.1:9080/openvim") |
| 199 | if verbose: print(datacenter) |
| 200 | client["datacenter_name"] = test_datacenter |
| 201 | to_delete_list.insert(0,{"item": "datacenter", "function": client.delete_datacenter, |
| 202 | "params":{ |
| 203 | "name": test_datacenter |
| 204 | } |
| 205 | }) |
| 206 | |
| 207 | print(" {}. TEST datacenter new tenenat".format(test_number)) |
| 208 | test_number += 1 |
| 209 | test_vim_tenant = "test-vimtenant "+\ |
| 210 | ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 211 | vim_tenant = client.vim_action("create", "tenants", datacenter_name=test_datacenter, all_tenants=True, name=test_vim_tenant) |
| 212 | if verbose: print(vim_tenant) |
| 213 | client["datacenter_name"] = test_datacenter |
| 214 | to_delete_list.insert(0,{"item": "vim_tenant", |
| 215 | "function": client.vim_action, |
| 216 | "params":{ |
| 217 | "action":"delete", |
| 218 | "item":"tenants", |
| 219 | "datacenter_name": test_datacenter, |
| 220 | "all_tenants": True, |
| 221 | "uuid": vim_tenant["tenant"]["id"] |
| 222 | } |
| 223 | }) |
| 224 | |
| 225 | print(" {}. TEST datacenter attach".format(test_number)) |
| 226 | test_number += 1 |
| 227 | datacenter = client.attach_datacenter(name=test_datacenter, vim_tenant_name=test_vim_tenant) |
| 228 | if verbose: print(datacenter) |
| 229 | client["datacenter_name"] = test_datacenter |
| 230 | to_delete_list.insert(0,{"item": "datacenter-detach", "function": client.detach_datacenter, "params":{"name": test_datacenter} }) |
| 231 | |
| 232 | client["datacenter_name"] = test_datacenter |
| Anderson Bravalheri | 0446cd5 | 2018-08-17 15:26:19 +0100 | [diff] [blame] | 233 | |
| 234 | # WIMs |
| 235 | print(" {}. TEST create_wim".format(test_number)) |
| 236 | test_number += 1 |
| 237 | long_name = _get_random_name(60) |
| 238 | |
| 239 | wim = client.create_wim(name=long_name, wim_url="http://fakeurl/fake") |
| 240 | if verbose: print(wim) |
| 241 | |
| 242 | print(" {}. TEST list_wims".format(test_number)) |
| 243 | test_number += 1 |
| 244 | wims = client.list_wims(all_tenants=True) |
| 245 | if verbose: print(wims) |
| 246 | |
| 247 | print(" {}. TEST list_tenans filter by name".format(test_number)) |
| 248 | test_number += 1 |
| 249 | wims_ = client.list_wims(all_tenants=True, name=long_name) |
| 250 | if not wims_["wims"]: |
| 251 | raise Exception("Text error, no TENANT found with name") |
| 252 | if verbose: print(wims_) |
| 253 | |
| 254 | print(" {}. TEST get_wim by UUID".format(test_number)) |
| 255 | test_number += 1 |
| 256 | wim = client.get_wim(uuid=wims_["wims"][0]["uuid"], all_tenants=True) |
| 257 | if verbose: print(wim) |
| 258 | |
| 259 | print(" {}. TEST delete_wim by name".format(test_number)) |
| 260 | test_number += 1 |
| 261 | wim = client.delete_wim(name=long_name) |
| 262 | if verbose: print(wim) |
| 263 | |
| 264 | print(" {}. TEST create_wim for remaining tests".format(test_number)) |
| 265 | test_number += 1 |
| 266 | test_wim = "test-wim " + \ |
| 267 | ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 268 | wim = client.create_wim(name=test_wim, vim_url="http://127.0.0.1:9080/odl") |
| 269 | if verbose: print(wim) |
| 270 | to_delete_list.insert(0, |
| 271 | { |
| 272 | "item": "wim", "function": client.delete_wim, |
| 273 | "params": |
| 274 | { |
| 275 | "name": test_wim |
| 276 | } |
| 277 | }) |
| 278 | |
| 279 | test_wim_tenant = "test-wimtenant " + \ |
| 280 | ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 281 | |
| 282 | # print(" {}. TEST datacenter new tenenat".format(test_number)) |
| 283 | # test_number += 1 |
| 284 | # test_vim_tenant = "test-vimtenant " + \ |
| 285 | # ''.join(random.choice('abcdefghijklmnopqrstuvwxyz') for _ in range(40)) |
| 286 | # vim_tenant = client.vim_action("create", "tenants", datacenter_name=test_datacenter, all_tenants=True, |
| 287 | # name=test_vim_tenant) |
| 288 | # if verbose: print(vim_tenant) |
| 289 | # client["datacenter_name"] = test_datacenter |
| 290 | # to_delete_list.insert(0, {"item": "vim_tenant", |
| 291 | # "function": client.vim_action, |
| 292 | # "params": { |
| 293 | # "action": "delete", |
| 294 | # "item": "tenants", |
| 295 | # "datacenter_name": test_datacenter, |
| 296 | # "all_tenants": True, |
| 297 | # "uuid": vim_tenant["tenant"]["id"] |
| 298 | # } |
| 299 | # }) |
| 300 | |
| 301 | print(" {}. TEST wim attach".format(test_number)) |
| 302 | test_number += 1 |
| 303 | wim = client.attach_wim(name=test_wim, wim_tenant_name=test_wim_tenant) |
| 304 | if verbose: print(wim) |
| 305 | to_delete_list.insert(0, {"item": "wim-detach", "function": client.detach_wim, |
| 306 | "params": {"name": test_wim}}) |
| tierno | f8fa9f0 | 2016-12-28 09:11:15 +0100 | [diff] [blame] | 307 | |
| 308 | #VIM_ACTIONS |
| 309 | print(" {}. TEST create_VIM_tenant".format(test_number)) |
| 310 | test_number += 1 |
| 311 | long_name = _get_random_name(60) |
| 312 | |
| 313 | tenant = client.vim_action("create", "tenants", name=long_name) |
| 314 | if verbose: print(tenant) |
| 315 | tenant_uuid = tenant["tenant"]["id"] |
| 316 | |
| 317 | print(" {}. TEST list_VIM_tenants".format(test_number)) |
| 318 | test_number += 1 |
| 319 | tenants = client.vim_action("list", "tenants") |
| 320 | if verbose: print(tenants) |
| 321 | |
| 322 | print(" {}. TEST get_VIM_tenant by UUID".format(test_number)) |
| 323 | test_number += 1 |
| 324 | tenant = client.vim_action("show", "tenants", uuid=tenant_uuid) |
| 325 | if verbose: print(tenant) |
| 326 | |
| 327 | print(" {}. TEST delete_VIM_tenant by id".format(test_number)) |
| 328 | test_number += 1 |
| 329 | tenant = client.vim_action("delete", "tenants", uuid = tenant_uuid) |
| 330 | if verbose: print(tenant) |
| 331 | |
| 332 | print(" {}. TEST create_VIM_network".format(test_number)) |
| 333 | test_number += 1 |
| 334 | long_name = _get_random_name(60) |
| 335 | |
| 336 | network = client.vim_action("create", "networks", name=long_name) |
| 337 | if verbose: print(network) |
| 338 | network_uuid = network["network"]["id"] |
| 339 | |
| 340 | print(" {}. TEST list_VIM_networks".format(test_number)) |
| 341 | test_number += 1 |
| 342 | networks = client.vim_action("list", "networks") |
| 343 | if verbose: print(networks) |
| 344 | |
| 345 | print(" {}. TEST get_VIM_network by UUID".format(test_number)) |
| 346 | test_number += 1 |
| 347 | network = client.vim_action("show", "networks", uuid=network_uuid) |
| 348 | if verbose: print(network) |
| 349 | |
| 350 | print(" {}. TEST delete_VIM_network by id".format(test_number)) |
| 351 | test_number += 1 |
| 352 | network = client.vim_action("delete", "networks", uuid = network_uuid) |
| 353 | if verbose: print(network) |
| 354 | #VNFS |
| 355 | print(" {}. TEST create_vnf".format(test_number)) |
| 356 | test_number += 1 |
| 357 | test_vnf_name = _get_random_name(255) |
| 358 | if test_image: |
| 359 | test_vnf_path = test_image |
| 360 | else: |
| 361 | test_vnf_path = "/random/path/" + "".join(random.choice('abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ') for _ in range(20)) |
| 362 | |
| 363 | vnf_descriptor={'vnf': {'name': test_vnf_name, |
| 364 | 'VNFC': [{'description': _get_random_name(255), |
| 365 | 'name': 'linux-VM', |
| 366 | 'VNFC image': test_vnf_path, |
| 367 | 'ram': 1024, |
| 368 | 'vcpus': 1, |
| 369 | 'bridge-ifaces': [{'name': 'eth0'}] |
| 370 | }], |
| 371 | 'description': _get_random_name(255), |
| 372 | 'nets': [], |
| 373 | 'external-connections': [{'name': 'eth0', |
| 374 | 'local_iface_name': 'eth0', |
| 375 | 'VNFC': 'linux-VM', |
| 376 | 'type': 'bridge'}], |
| 377 | 'public': False}} |
| 378 | |
| 379 | vnf = client.create_vnf(descriptor=vnf_descriptor) |
| 380 | if verbose: print(vnf) |
| 381 | to_delete_list.insert(0,{"item": "vnf", "function": client.delete_vnf, "params":{"name": test_vnf_name} }) |
| 382 | |
| 383 | print(" {}. TEST list_vnfs".format(test_number)) |
| 384 | test_number += 1 |
| 385 | vnfs = client.list_vnfs() |
| 386 | if verbose: print(vnfs) |
| 387 | |
| 388 | print(" {}. TEST list_vnfs filter by name".format(test_number)) |
| 389 | test_number += 1 |
| 390 | vnfs_ = client.list_vnfs(name=test_vnf_name) |
| 391 | if not vnfs_["vnfs"]: |
| 392 | raise Exception("Text error, no VNF found with name") |
| 393 | if verbose: print(vnfs_) |
| 394 | |
| 395 | print(" {}. TEST get_vnf by UUID".format(test_number)) |
| 396 | test_number += 1 |
| 397 | vnf = client.get_vnf(uuid=vnfs_["vnfs"][0]["uuid"]) |
| 398 | if verbose: print(vnf) |
| 399 | |
| 400 | #SCENARIOS |
| 401 | print(" {}. TEST create_scenario".format(test_number)) |
| 402 | test_number += 1 |
| 403 | test_scenario_name = _get_random_name(255) |
| 404 | |
| 405 | scenario_descriptor={ 'schema_version': 2, |
| 406 | 'scenario': { |
| 407 | 'name': test_scenario_name, |
| 408 | 'description': _get_random_name(255), |
| 409 | 'public': True, |
| 410 | 'vnfs':{ |
| 411 | 'vnf1': { |
| 412 | 'vnf_name': test_vnf_name |
| 413 | } |
| 414 | }, |
| 415 | 'networks':{ |
| 416 | 'net1':{ |
| 417 | 'external': True, |
| 418 | 'interfaces': [ |
| 419 | {'vnf1': 'eth0'} |
| 420 | ] |
| 421 | } |
| 422 | } |
| 423 | } |
| 424 | } |
| 425 | |
| 426 | scenario = client.create_scenario(descriptor=scenario_descriptor) |
| 427 | if verbose: print(scenario) |
| 428 | to_delete_list.insert(0,{"item": "scenario", "function": client.delete_scenario, "params":{"name": test_scenario_name} }) |
| 429 | |
| 430 | print(" {}. TEST list_scenarios".format(test_number)) |
| 431 | test_number += 1 |
| 432 | scenarios = client.list_scenarios() |
| 433 | if verbose: print(scenarios) |
| 434 | |
| 435 | print(" {}. TEST list_scenarios filter by name".format(test_number)) |
| 436 | test_number += 1 |
| 437 | scenarios_ = client.list_scenarios(name=test_scenario_name) |
| 438 | if not scenarios_["scenarios"]: |
| 439 | raise Exception("Text error, no VNF found with name") |
| 440 | if verbose: print(scenarios_) |
| 441 | |
| 442 | print(" {}. TEST get_scenario by UUID".format(test_number)) |
| 443 | test_number += 1 |
| 444 | scenario = client.get_scenario(uuid=scenarios_["scenarios"][0]["uuid"]) |
| 445 | if verbose: print(scenario) |
| 446 | |
| 447 | |
| 448 | |
| 449 | #INSTANCES |
| 450 | print(" {}. TEST create_instance".format(test_number)) |
| 451 | test_number += 1 |
| 452 | test_instance_name = _get_random_name(255) |
| 453 | |
| 454 | instance_descriptor={ 'schema_version': 2, |
| 455 | 'instance': { |
| 456 | 'name': test_instance_name, |
| 457 | 'description': _get_random_name(255), |
| 458 | 'public': True, |
| 459 | 'vnfs':{ |
| 460 | 'vnf1': { |
| 461 | 'vnf_name': test_vnf_name |
| 462 | } |
| 463 | }, |
| 464 | 'networks':{ |
| 465 | 'net1':{ |
| 466 | 'external': True, |
| 467 | 'interfaces': [ |
| 468 | {'vnf1': 'eth0'} |
| 469 | ] |
| 470 | } |
| 471 | } |
| 472 | } |
| 473 | } |
| 474 | |
| 475 | instance = client.create_instance(scenario_name=test_scenario_name, name=test_instance_name ) |
| 476 | if verbose: print(instance) |
| 477 | to_delete_list.insert(0,{"item": "instance", "function": client.delete_instance, "params":{"name": test_instance_name} }) |
| 478 | |
| 479 | print(" {}. TEST list_instances".format(test_number)) |
| 480 | test_number += 1 |
| 481 | instances = client.list_instances() |
| 482 | if verbose: print(instances) |
| 483 | |
| 484 | print(" {}. TEST list_instances filter by name".format(test_number)) |
| 485 | test_number += 1 |
| 486 | instances_ = client.list_instances(name=test_instance_name) |
| 487 | if not instances_["instances"]: |
| 488 | raise Exception("Text error, no VNF found with name") |
| 489 | if verbose: print(instances_) |
| 490 | |
| 491 | print(" {}. TEST get_instance by UUID".format(test_number)) |
| 492 | test_number += 1 |
| 493 | instance = client.get_instance(uuid=instances_["instances"][0]["uuid"]) |
| 494 | if verbose: print(instance) |
| 495 | |
| 496 | |
| 497 | |
| 498 | |
| 499 | #DELETE Create things |
| 500 | for item in to_delete_list: |
| 501 | print(" {}. TEST delete_{}".format(test_number, item["item"])) |
| 502 | test_number += 1 |
| 503 | response = item["function"](**item["params"]) |
| 504 | if verbose: print(response) |
| 505 | |