diff options
-rw-r--r-- | test/unit/path.moon | 3 |
1 files changed, 2 insertions, 1 deletions
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', -> |