Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Cedric Halbronn committed May 20, 2024
1 parent 08c6ed5 commit 4c70fda
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 2 deletions.
10 changes: 9 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:
#app_version: [v0.9.5]
# NB: Nightly is NVIM v0.11.0-dev-25+g0e187fe03 in May 2024
app_version: [v0.9.5, v0.10.0, stable, nightly]
node_version: [v20.12.1, v21.7.1]
# XXX: restore this once neovim tests work in CI
# include:
# - os: ubuntu-latest
Expand All @@ -46,7 +47,7 @@ jobs:
with:
# XXX - v20.12.1 taken from .nvmrc file?
# node-version-file: .nvmrc
node-version: v21.7.1
node-version: $${{ matrix.node_version }}
cache: pnpm
# XXX testing only
# - run: dir ${{ github.workspace }}
Expand Down Expand Up @@ -76,7 +77,10 @@ jobs:
# Current working directory:
# - Windows: D:\a\cursorless\cursorless
# - Linux: /home/runner/work/cursorless/cursorless
# - OS X: /Users/runner/work/cursorless/cursorless
- run: pwd
- run: tree /Users/runner/work/cursorless/cursorless/dist
if: runner.os == 'macOS'
- run: tree /home/runner/work/cursorless/cursorless/dist
if: runner.os == 'Linux'
- run: tree /f D:\a\cursorless\cursorless\dist
Expand Down Expand Up @@ -109,6 +113,10 @@ jobs:
if: runner.os == 'Linux'
- run: git clone https://github.com/hands-free-vim/talon.nvim /home/runner/talon.nvim
if: runner.os == 'Linux'
- run: git clone https://github.com/vim-scripts/BufOnly.vim /Users/runner//BufOnly.vim
if: runner.os == 'Linux'
- run: git clone https://github.com/hands-free-vim/talon.nvim /Users/runner//talon.nvim
if: runner.os == 'Linux'
# - run: C:\Users\runneradmin\nvim-stable\bin\nvim.exe -l ${{ github.workspace }}\packages\test-harness\src\config\empty.lua
# C:\Users\runneradmin\nvim-stable\bin\nvim.exe: D:\a\_temp\2658188c-43d2-4fce-9de9-299408299ebb.ps1:2
# Line |
Expand Down
9 changes: 9 additions & 0 deletions packages/test-harness/src/config/init_mac.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
vim.cmd('source /Users/runner/BufOnly.vim/plugin/BufOnly.vim')

vim.o.runtimepath = vim.o.runtimepath .. ',' .. '/Users/runner/talon.nvim'
vim.o.runtimepath = vim.o.runtimepath
.. ','
.. '/Users/runner/work/cursorless/cursorless/dist/cursorless.nvim'

require('talon').setup()
require('cursorless').setup()
8 changes: 7 additions & 1 deletion packages/test-harness/src/launchNeovimAndRunTests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,16 @@ export async function launchNeovimAndRunTests(extensionTestsPath: string) {
if (process.platform === "win32") {
nvimFolder = "C:/Users/runneradmin/AppData/Local/nvim\\";
initLuaFile = `${getCursorlessRepoRoot()}/packages/test-harness/src/config/init_win.lua`;
} else {
} else if (process.platform === "linux") {
//XXX: ~/.config/nvim/ does not work?
nvimFolder = "/home/runner/.config/nvim/";
initLuaFile = `${getCursorlessRepoRoot()}/packages/test-harness/src/config/init_linux.lua`;
} else if (process.platform === "darwin") {
nvimFolder = "/Users/runner/.config/nvim/";
initLuaFile = `${getCursorlessRepoRoot()}/packages/test-harness/src/config/init_mac.lua`;
} else {
console.error(`Unsupported platform: ${process.platform}`);
process.exit(1);
}

console.log(`cli: ${cli}`);
Expand Down

0 comments on commit 4c70fda

Please sign in to comment.