aboutsummaryrefslogtreecommitdiff
path: root/test/functional/legacy/031_close_commands_spec.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2016-09-20 12:32:42 +0200
committerGitHub <noreply@github.com>2016-09-20 12:32:42 +0200
commitbba6315580814bcd2b2dea8340a4d47265854949 (patch)
tree6a5dc23a6291a95af4190e1950f6a5da60894a4a /test/functional/legacy/031_close_commands_spec.lua
parentefe8311371830930b2ab14937b8d6adc801cc99b (diff)
parent911421d328a91a56389248fe27bee6c95784d95f (diff)
downloadrneovim-bba6315580814bcd2b2dea8340a4d47265854949.tar.gz
rneovim-bba6315580814bcd2b2dea8340a4d47265854949.tar.bz2
rneovim-bba6315580814bcd2b2dea8340a4d47265854949.zip
Merge #5362 from justinmk/testcleanup
test: helpers.rmdir(): retry+sleep on failure
Diffstat (limited to 'test/functional/legacy/031_close_commands_spec.lua')
-rw-r--r--test/functional/legacy/031_close_commands_spec.lua19
1 files changed, 12 insertions, 7 deletions
diff --git a/test/functional/legacy/031_close_commands_spec.lua b/test/functional/legacy/031_close_commands_spec.lua
index eaf4e2982f..d41eadaa00 100644
--- a/test/functional/legacy/031_close_commands_spec.lua
+++ b/test/functional/legacy/031_close_commands_spec.lua
@@ -19,7 +19,18 @@ local expect = helpers.expect
local execute = helpers.execute
describe('Commands that close windows and/or buffers', function()
- setup(clear)
+ local function cleanup()
+ os.remove('Xtest1')
+ os.remove('Xtest2')
+ os.remove('Xtest3')
+ end
+ setup(function()
+ cleanup()
+ clear()
+ end)
+ teardown(function()
+ cleanup()
+ end)
it('is working', function()
insert('testtext')
@@ -112,10 +123,4 @@ describe('Commands that close windows and/or buffers', function()
" Now nvim should have exited
throw "Oh, Not finished yet."]])
end)
-
- teardown(function()
- os.remove('Xtest1')
- os.remove('Xtest2')
- os.remove('Xtest3')
- end)
end)