From daa229bfde9ceabbb5454a7598d1c9de37cbdbb2 Mon Sep 17 00:00:00 2001 From: Barrett Ruth <62671086+barrettruth@users.noreply.github.com> Date: Wed, 1 Jul 2026 13:45:55 -0500 Subject: fix(dir): restore loaded plugin guard #40528 --- test/functional/plugin/dir_spec.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'test/functional/plugin/dir_spec.lua') diff --git a/test/functional/plugin/dir_spec.lua b/test/functional/plugin/dir_spec.lua index e91bdc11c0..9bd98fac0d 100644 --- a/test/functional/plugin/dir_spec.lua +++ b/test/functional/plugin/dir_spec.lua @@ -364,7 +364,7 @@ describe('nvim.dir', function() eq('', api.nvim_get_option_value('filetype', { buf = 0 })) end) - it('coexists with netrw', function() + it('coexists with netrw and can be disabled', function() if t.is_zig_build() then return pending('broken with build.zig relative runtime paths after chdir') end @@ -380,6 +380,13 @@ describe('nvim.dir', function() command('Explore .') cd(cwd) eq('netrw', api.nvim_get_option_value('filetype', { buf = 0 })) + + n.clear({ + args_rm = { '-u' }, + args = { '--cmd', 'let g:loaded_nvim_dir_plugin = 1' }, + }) + edit(root) + eq('netrw', api.nvim_get_option_value('filetype', { buf = 0 })) end) it('supports the FileExplorer browse contract', function() -- cgit