-
Notifications
You must be signed in to change notification settings - Fork 2
48 lines (42 loc) · 1.22 KB
/
Copy pathtest.yml
File metadata and controls
48 lines (42 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Tests
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
emacs-version: ['29.4', '30.1']
shell: ['bash', 'zsh']
steps:
- name: Check out
uses: actions/checkout@v4
- name: Cache Emacs
uses: actions/cache@v4
with:
path: ~/.emacs.d
key: ${{ runner.os }}-emacs-${{ matrix.emacs-version }}
- name: Install Emacs
uses: purcell/setup-emacs@master
with:
version: ${{ matrix.emacs-version }}
- name: Install zsh
if: matrix.shell == 'zsh'
run: |
sudo apt-get update
sudo apt-get install -y zsh
- name: Start Emacs daemon
run: |
emacs --daemon
# Wait for daemon to be ready
timeout 10 bash -c 'until emacsclient --eval "t" 2>/dev/null; do sleep 0.5; done'
- name: Run tests with ${{ matrix.shell }}
run: |
if [ "${{ matrix.shell }}" = "zsh" ]; then
zsh -c 'setopt SH_WORD_SPLIT && make test-ci'
else
make test-ci
fi
- name: Stop Emacs daemon
if: always()
run: emacsclient --eval "(kill-emacs)" || true