Skip to content

ci: run Positron API tests on ubuntu-latest - #43

Merged
ntluong95 merged 1 commit into
TidierOrg:mainfrom
jonvanausdeln:positron-api-tests-ubuntu
Aug 21, 2026
Merged

ntluong95 merged 1 commit into
TidierOrg:mainfrom
jonvanausdeln:positron-api-tests-ubuntu

Conversation

@jonvanausdeln

@jonvanausdeln jonvanausdeln commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

What

Moves the Positron API Tests workflow from macos-latest to ubuntu-latest.

Why

When these tests landed in #41, the test runner
(@posit-dev/positron-test-electron)
could only download macOS builds of Positron, so the job had to run on a macOS
runner. Version 0.0.3 adds Windows and Linux support, and Positron now
publishes the Linux archives it needs — so the macOS constraint is gone.

Linux is the cheapest runner tier GitHub offers — a tenth of the minute
multiplier of macOS — and the runners are more plentiful, so jobs start sooner.
This repo is public, so standard runners are free either way; the win is faster
starts, a shorter job, and not holding a scarce macOS runner for work that
doesn't need one.

Changes

  • .github/workflows/positron-api-tests.yaml
    • runs-on: macos-latestubuntu-latest (and drop the now-stale
      "macOS only" comment).
    • Run the test command under xvfb-run -a. Positron is an Electron app, and
      on Linux it needs a display server — without this it fails with
      Missing X server or $DISPLAY.
    • Pin posit-dev/setup-positron to the v1 tag instead of tracking main,
      so future changes to that action can't break this repo's CI unannounced.
    • Include runner.os in the Positron download cache key. The archive layout
      differs per platform, so a cache saved by one OS shouldn't count as a hit
      for another. (Happy to drop this one if you'd rather keep the diff to the
      runner switch.)
  • package.json / package-lock.json — bump
    @posit-dev/positron-test-electron ^0.0.2^0.0.3 (the version that
    added Linux support).
  • scripts/run-positron-tests.mjs, src/test/positron/README.md — refresh the
    "macOS only" notes, which are no longer true, and document the xvfb-run
    requirement for running the suite locally on Linux.

No test code changed.

Verification

Green on ubuntu-latest in my fork: https://github.com/jonvanausdeln/positron-julia/actions/runs/32173307802

All 4 tests pass in a real Positron (stable 2026.08.1-2) on Linux — the
extension activates and a Julia runtime surfaces via getRegisteredRuntimes /
getPreferredRuntime, the same assertions that were passing on macOS. The job
took 1m23s, versus about 2 minutes for the recent macos-latest runs on
main.

@posit-dev/positron-test-electron 0.0.3 adds Windows and Linux support
(0.0.2 was macOS-only), so the suite no longer needs a macOS runner.
Linux runners are cheaper and faster to schedule.

Positron is an Electron app, so on Linux it needs a display server: the
test command now runs under xvfb-run.

Also pin posit-dev/setup-positron to the v1 tag instead of tracking main,
so upstream changes to the action can't break CI unannounced, and scope
the Positron download cache key to runner.os, since the archive layout
differs per platform.
@ntluong95
ntluong95 merged commit 5e63426 into TidierOrg:main Aug 21, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants