File tree Expand file tree Collapse file tree 4 files changed +33
-5
lines changed
Expand file tree Collapse file tree 4 files changed +33
-5
lines changed Original file line number Diff line number Diff line change 1- local plugin_root = vim .fn .expand (' $PWD' )
1+ local plugin_root = vim .fn .getcwd ()
2+
3+ vim .notify (plugin_root )
24vim .opt .runtimepath :append (plugin_root )
35
46local plenary_path = plugin_root .. ' /deps/plenary.nvim'
5- if vim .fn .isdirectory (plenary_path ) == 1 then
6- vim .opt .runtimepath :append (plenary_path )
7+
8+ -- Check if plenary exists, if not, clone it
9+ if vim .fn .isdirectory (plenary_path ) ~= 1 then
10+ -- Create deps directory if it doesn't exist
11+ if vim .fn .isdirectory (plugin_root .. ' /deps' ) ~= 1 then
12+ vim .fn .mkdir (plugin_root .. ' /deps' , ' p' )
13+ end
14+
15+ print (' Cloning plenary.nvim for testing...' )
16+ local clone_cmd = ' git clone --depth 1 https://github.com/nvim-lua/plenary.nvim.git ' .. plenary_path
17+ vim .fn .system (clone_cmd )
718end
819
20+ vim .opt .runtimepath :append (plenary_path )
21+
922vim .o .laststatus = 3
1023vim .o .termguicolors = true
1124vim .g .mapleader = ' '
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ M.headless_mode = false
1414
1515function M .load_events (file_path )
1616 file_path = file_path or ' tests/data/simple-session.json'
17- local data_file = vim .fn .expand ( ' $PWD ' ) .. ' /' .. file_path
17+ local data_file = vim .fn .getcwd ( ) .. ' /' .. file_path
1818 local f = io.open (data_file , ' r' )
1919 if not f then
2020 vim .notify (' Could not open ' .. data_file , vim .log .levels .ERROR )
Original file line number Diff line number Diff line change 1+ # Get the directory containing this script
2+ $ScriptDir = Split-Path - Parent $MyInvocation.MyCommand.Definition
3+
4+ # Get the project root (two directories up)
5+ $ProjectRoot = Resolve-Path (Join-Path $ScriptDir " ..\.." )
6+
7+ # Change to project root
8+ Set-Location $ProjectRoot
9+
10+ Write-Host " Starting Streaming Renderer Replay Test..."
11+ Write-Host " "
12+
13+ # Run Neovim with the test init file, passing all arguments through
14+ nvim - u " tests/manual/init_replay.lua" @Args
15+
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ vim.opt.runtimepath:remove(vim.fn.expand('~/.config/nvim'))
66vim .opt .packpath :remove (vim .fn .expand (' ~/.local/share/nvim/site' ))
77
88-- Add the plugin to the runtimepath
9- local plugin_root = vim .fn .expand ( ' $PWD ' )
9+ local plugin_root = vim .fn .getcwd ( )
1010vim .opt .runtimepath :append (plugin_root )
1111
1212-- Add plenary to the runtimepath for testing
You can’t perform that action at this time.
0 commit comments