Fix how we get the cwd for tests