added print statements to test for cwd