aboutsummaryrefslogtreecommitdiff
path: root/test/unit/undo_spec.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2019-05-18 14:09:43 +0200
committerJustin M. Keyes <justinkz@gmail.com>2019-05-18 15:48:13 +0200
commitfd04877eb087b64d744a20db643f3abd630c70aa (patch)
treef5dadcc24cba5b83157657143a2aa9c0d91d6473 /test/unit/undo_spec.lua
parent7669fc1e9b9dba015597974f4a2b46f2439b48da (diff)
downloadrneovim-fd04877eb087b64d744a20db643f3abd630c70aa.tar.gz
rneovim-fd04877eb087b64d744a20db643f3abd630c70aa.tar.bz2
rneovim-fd04877eb087b64d744a20db643f3abd630c70aa.zip
test: remove use of require('test.helpers')
The test.functional.helpers and test.unit.helpers modules now include all of the public functions from test.helpers, so there is no need to separately require('test.helpers').
Diffstat (limited to 'test/unit/undo_spec.lua')
-rw-r--r--test/unit/undo_spec.lua8
1 files changed, 3 insertions, 5 deletions
diff --git a/test/unit/undo_spec.lua b/test/unit/undo_spec.lua
index f23110b329..616c6fbe3d 100644
--- a/test/unit/undo_spec.lua
+++ b/test/unit/undo_spec.lua
@@ -2,9 +2,7 @@ local helpers = require('test.unit.helpers')(after_each)
local itp = helpers.gen_itp(it)
local lfs = require('lfs')
local child_call_once = helpers.child_call_once
-
-local global_helpers = require('test.helpers')
-local sleep = global_helpers.sleep
+local sleep = helpers.sleep
local ffi = helpers.ffi
local cimport = helpers.cimport
@@ -156,12 +154,12 @@ describe('u_write_undo', function()
local file_contents = "testing permissions"
-- Write a text file where the undofile should go
local correct_name = ffi.string(undo.u_get_undo_file_name(file_buffer.b_ffname, false))
- global_helpers.write_file(correct_name, file_contents, true, false)
+ helpers.write_file(correct_name, file_contents, true, false)
-- Call with `forceit`.
u_write_undo(correct_name, true, file_buffer, buffer_hash)
- local undo_file_contents = global_helpers.read_file(correct_name)
+ local undo_file_contents = helpers.read_file(correct_name)
neq(file_contents, undo_file_contents)
local success, deletion_err = os.remove(correct_name) -- delete the file now that we're done with it.