aboutsummaryrefslogtreecommitdiff
path: root/test/unit/os/fs_spec.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-08-10 03:59:43 +0200
committerGitHub <noreply@github.com>2017-08-10 03:59:43 +0200
commitde1084f3c48816e96be3cac28bcf56bd321ad800 (patch)
tree79fde721bd1c0ae176670faae2122957e10280b0 /test/unit/os/fs_spec.lua
parent085102fadf1c1371e863c0e9af8240038ce641e2 (diff)
parent7ae744b93d80fd169507732931606276844150b6 (diff)
downloadrneovim-de1084f3c48816e96be3cac28bcf56bd321ad800.tar.gz
rneovim-de1084f3c48816e96be3cac28bcf56bd321ad800.tar.bz2
rneovim-de1084f3c48816e96be3cac28bcf56bd321ad800.zip
Merge #7140 'os_stat: return ENOENT on NULL fname'
Diffstat (limited to 'test/unit/os/fs_spec.lua')
-rw-r--r--test/unit/os/fs_spec.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/unit/os/fs_spec.lua b/test/unit/os/fs_spec.lua
index 23eb05b4b8..bc39507c08 100644
--- a/test/unit/os/fs_spec.lua
+++ b/test/unit/os/fs_spec.lua
@@ -862,6 +862,11 @@ describe('fs.c', function()
end
describe('os_fileinfo', function()
+ itp('returns false if path=NULL', function()
+ local file_info = file_info_new()
+ assert.is_false((fs.os_fileinfo(nil, file_info)))
+ end)
+
itp('returns false if given a non-existing file', function()
local file_info = file_info_new()
assert.is_false((fs.os_fileinfo('/non-existent', file_info)))