Skip to content

Commit 992c260

Browse files
committed
Set up harness for continuous testing
1 parent 7aad3b5 commit 992c260

File tree

4 files changed

+20
-3
lines changed

4 files changed

+20
-3
lines changed

.github/workflows/test.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,17 @@ jobs:
2626
steps:
2727
- uses: actions/checkout@v3
2828

29+
- name: Setup Java # SonarLint runs on Java.
30+
uses: actions/setup-java@v3
31+
with:
32+
distribution: 'temurin'
33+
java-version: 11
34+
35+
- name: Setup NodeJS # for JS and TS analyzer
36+
uses: actions/setup-node@v3
37+
with:
38+
node-version: 16
39+
2940
- uses: jcs090218/setup-emacs@master
3041
with:
3142
version: ${{ matrix.emacs-version }}

Eask

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,7 @@
1919
(depends-on "lsp-mode" "6.3")
2020
(depends-on "ht" "2.3")
2121

22+
(development
23+
(depends-on "ert"))
24+
2225
(setq network-security-level 'low) ; see https://github.com/jcs090218/setup-emacs-windows/issues/156#issuecomment-932956432

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ SHELL := /usr/bin/env bash
33
EMACS ?= emacs
44
EASK ?= eask
55

6-
TEST-FILES := $(shell ls test/lsp-sonarlint-*.el)
6+
TEST-FILES := $(shell ls test/*.el)
77

88
.PHONY: clean checkdoc lint package install compile test
99

10-
ci: clean package install compile
10+
ci: clean package install compile test
1111

1212
package:
1313
@echo "Packaging..."
@@ -23,7 +23,7 @@ compile:
2323

2424
test:
2525
@echo "Testing..."
26-
$(EASK) exec ert-runner -L . $(LOAD-TEST-FILES) -t '!no-win' -t '!org'
26+
$(EASK) test ert $(TEST-FILES)
2727

2828
clean:
2929
$(EASK) clean all

test/trivial-test.el

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
(ert-deftest trivial-test-to-make-sure-testing-framework-works ()
2+
"Check whether the testing framework itself can accept a passing test."
3+
(should (equal (+ 1 1) 2)))

0 commit comments

Comments
 (0)