Fix getting cwd in test bootstrap