aboutsummaryrefslogtreecommitdiff
path: root/test/testutil.lua
diff options
context:
space:
mode:
authorWillaaaaaaa <willaaaaaaa936@gmail.com>2026-03-12 17:46:18 +0800
committerGitHub <noreply@github.com>2026-03-12 05:46:18 -0400
commitc5146362d8564b581042a82019cbae3f7d0d4843 (patch)
tree2e759538aaa41b74f15689d9c9f571936c06755e /test/testutil.lua
parent32aee065a898aa125e5ae87dcce513606112398d (diff)
downloadrneovim-c5146362d8564b581042a82019cbae3f7d0d4843.tar.gz
rneovim-c5146362d8564b581042a82019cbae3f7d0d4843.tar.bz2
rneovim-c5146362d8564b581042a82019cbae3f7d0d4843.zip
test: fs_spec fails if home is a symlink #38258
Diffstat (limited to 'test/testutil.lua')
-rw-r--r--test/testutil.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/testutil.lua b/test/testutil.lua
index bffd9763b5..8a07571e3a 100644
--- a/test/testutil.lua
+++ b/test/testutil.lua
@@ -106,6 +106,11 @@ function M.neq(expected, actual, context)
return luaassert.are_not.same(expected, actual, context)
end
+--- Compare paths after resolving symlinks with realpath.
+function M.eq_paths(expected, actual, context)
+ return M.eq(uv.fs_realpath(expected), uv.fs_realpath(actual), context)
+end
+
--- Asserts that `cond` is true, or prints a message.
---
--- @param cond (boolean) expression to assert