This function checks whether testing is required and if so, sets up a Queue for the purpose of communicating with the thread. then it starts the after waiting 5 seconds for the server to have a chance to start up.
()
| 233 | # Initialize the test client |
| 234 | # ============================================================================= |
| 235 | def _start_test_thread(): |
| 236 | """ |
| 237 | This function checks whether testing is required and if so, sets up a Queue |
| 238 | for the purpose of communicating with the thread. then it starts the |
| 239 | after waiting 5 seconds for the server to have a chance to start up. |
| 240 | """ |
| 241 | |
| 242 | global test_module_comm_queue |
| 243 | test_module_comm_queue = Queue.Queue() |
| 244 | |
| 245 | t = threading.Thread( |
| 246 | target=launch_web_test, |
| 247 | args=[], |
| 248 | kwargs={ |
| 249 | "serverOpts": testModuleOptions, |
| 250 | "commQueue": test_module_comm_queue, |
| 251 | "testScript": testModuleOptions.testScriptPath, |
| 252 | }, |
| 253 | ) |
| 254 | |
| 255 | t.start() |
| 256 | |
| 257 | |
| 258 | # ============================================================================= |