Skip to content

Commit

Permalink
CI: Register github action
Browse files Browse the repository at this point in the history
  • Loading branch information
LucHermitte committed Aug 23, 2024
1 parent f65e2d2 commit 7b2c8e1
Showing 1 changed file with 58 additions and 0 deletions.
58 changes: 58 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby

name: CI

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

permissions:
contents: read

jobs:
test:
name: "test on ${{ matrix.os }} ; ${{ matrix.neovim && 'neovim' || 'vim' }}"

strategy:
matrix:
# Testing doesn't seem to work on Windows: output log file
# cannot be read...
# os: [ubuntu-latest, macos-latest, windows-latest]
os: [ubuntu-latest, macos-latest]
neovim: [false, true]
# TODO: Test different flavours of Vim...

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Setup Vim
uses: rhysd/action-setup-vim@v1
# uses: thinca/action-setup-vim@v2
id: vim
with:
neovim: ${{matrix.neovim }}
configure-args: |
--with-features=huge
- name: Run tests on Linux
if: runner.os == 'Linux' # headless execution is required on Linux
run: |
xvfb-run bundle exec rake ci
- name: Run tests on ${{ matrix.os }}
if: runner.os != 'Linux'
run: |
bundle exec rake ci

0 comments on commit 7b2c8e1

Please sign in to comment.