aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ex_cmds/profile_spec.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2024-09-02 15:52:18 -0700
committerGitHub <noreply@github.com>2024-09-02 15:52:18 -0700
commitae9674704ac5586438f60c883e918d448ef0e237 (patch)
treeb621a6b44c8f95b3db18274b4e6d0f319cdbd391 /test/functional/ex_cmds/profile_spec.lua
parentef8067a19d981388a14407ea08245811cf5b3604 (diff)
parent96128a5076b7e45fc01163151401a9e2acdff565 (diff)
downloadrneovim-ae9674704ac5586438f60c883e918d448ef0e237.tar.gz
rneovim-ae9674704ac5586438f60c883e918d448ef0e237.tar.bz2
rneovim-ae9674704ac5586438f60c883e918d448ef0e237.zip
Merge #30237 validate --listen address
Diffstat (limited to 'test/functional/ex_cmds/profile_spec.lua')
-rw-r--r--test/functional/ex_cmds/profile_spec.lua9
1 files changed, 2 insertions, 7 deletions
diff --git a/test/functional/ex_cmds/profile_spec.lua b/test/functional/ex_cmds/profile_spec.lua
index 57e5c6b2dc..365583948b 100644
--- a/test/functional/ex_cmds/profile_spec.lua
+++ b/test/functional/ex_cmds/profile_spec.lua
@@ -6,17 +6,11 @@ require('os')
local eval = n.eval
local command = n.command
local eq, neq = t.eq, t.neq
-local tempfile = t.tmpname()
+local tempfile = t.tmpname(false)
local source = n.source
local matches = t.matches
local read_file = t.read_file
--- tmpname() also creates the file on POSIX systems. Remove it again.
--- We just need the name, ignoring any race conditions.
-if uv.fs_stat(tempfile).uid then
- os.remove(tempfile)
-end
-
local function assert_file_exists(filepath)
neq(nil, uv.fs_stat(filepath).uid)
end
@@ -31,6 +25,7 @@ describe(':profile', function()
after_each(function()
n.expect_exit(command, 'qall!')
if uv.fs_stat(tempfile).uid ~= nil then
+ -- Delete the tempfile. We just need the name, ignoring any race conditions.
os.remove(tempfile)
end
end)