From d84fe0a1b0df64f07ba14137ae94bb843ad4fe2d Mon Sep 17 00:00:00 2001 From: Thomas Wienecke Date: Thu, 1 May 2014 23:00:14 +0200 Subject: Fix unit test cleanup of path_shorten_fname_if_possible. --- test/unit/path.moon | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/unit/path.moon b/test/unit/path.moon index 616fa2f076..6aecdfe67c 100644 --- a/test/unit/path.moon +++ b/test/unit/path.moon @@ -113,10 +113,11 @@ describe 'path function', -> eq 'directory/file.txt', (ffi.string path.path_shorten_fname full, dir) describe 'path_shorten_fname_if_possible', -> + cwd = lfs.currentdir! before_each -> lfs.mkdir 'ut_directory' after_each -> - lfs.chdir '..' + lfs.chdir cwd lfs.rmdir 'ut_directory' describe 'path_shorten_fname_if_possible', -> -- cgit