Moved $config and $tests_directory back out of main loop, fixes expectations!