fixed bad string in output file; fixed tests