fixed tests, create output dir