From 439a411ca47cf018751d3bc85dae0bd44821e6db Mon Sep 17 00:00:00 2001 From: Tomos Corbin Date: Wed, 22 Jul 2026 22:35:14 +0100 Subject: [PATCH 1/2] ci: run lint and test suites on GitHub Actions Mirrors the Makefile targets: stylua/ruff format checks, ruff lint, strict mypy, pytest, and the plenary specs on headless Neovim. Runs on pushes to main and on all pull requests. --- .github/workflows/ci.yml | 49 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..3208f53 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,49 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: astral-sh/setup-uv@v5 + - name: stylua format check + uses: JohnnyMorganz/stylua-action@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + version: latest + args: --check lua plugin tests + - name: ruff format check + run: cd python && uv run --extra test ruff format --check databricks_kernel_dialect tests + - name: ruff lint + run: cd python && uv run --extra test ruff check databricks_kernel_dialect tests + - name: mypy + run: cd python && uv run --extra test mypy databricks_kernel_dialect + + test-python: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: astral-sh/setup-uv@v5 + - name: pytest + run: cd python && uv run --extra test pytest -v + + test-lua: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: rhysd/action-setup-vim@v1 + with: + neovim: true + version: stable + - name: Install plenary.nvim + run: | + mkdir -p ~/.local/share/nvim/lazy + git clone --depth 1 https://github.com/nvim-lua/plenary.nvim \ + ~/.local/share/nvim/lazy/plenary.nvim + - name: plenary specs + run: make test-lua From e2ebd4245e9f54dc8ffbc161e6ec93f1a9e42a77 Mon Sep 17 00:00:00 2001 From: Tomos Corbin Date: Wed, 22 Jul 2026 22:36:33 +0100 Subject: [PATCH 2/2] style: format activate_spec per stylua --- tests/databricks-notebook/activate_spec.lua | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/databricks-notebook/activate_spec.lua b/tests/databricks-notebook/activate_spec.lua index 95d9502..eefc92b 100644 --- a/tests/databricks-notebook/activate_spec.lua +++ b/tests/databricks-notebook/activate_spec.lua @@ -405,8 +405,13 @@ describe("activation", function() vim.cmd("edit!") vim.api.nvim_buf_set_lines(bufnr, 2, 2, false, { "# MAGIC body" }) - local marks = - vim.api.nvim_buf_get_extmarks(bufnr, require("databricks-notebook.appearance").namespace(), 0, -1, { details = true }) + local marks = vim.api.nvim_buf_get_extmarks( + bufnr, + require("databricks-notebook.appearance").namespace(), + 0, + -1, + { details = true } + ) local conceal_marks = vim.tbl_filter(function(mark) return mark[4].conceal ~= nil end, marks)