def test_bad_path(self): " bad path should return same as default (and warn) " d = build_tools.configure_build_dir('_bad_path_') d2 = build_tools.configure_build_dir() assert_(d == d2) assert_(is_writable(d))
def test_pardir(self): " make sure it handles relative values " d = build_tools.configure_build_dir('..') if is_writable('..'): assert_(d == os.path.abspath('..')) assert_(is_writable(d))
def test_default(self): " default behavior is to return current directory " d = build_tools.configure_build_dir() if is_writable('.'): assert_(d == os.path.abspath('.')) assert_(is_writable(d))