branch: elpa/cider
commit 5bb6d98b27e3ba71a85d645144b6f12e2fd210eb
Author: ikappaki <ikapp...@users.noreply.github.com>
Commit: Bozhidar Batsov <bozhi...@batsov.dev>

    Add emacs-28.1 to CI
---
 .circleci/config.yml       | 11 ++++++++++-
 .github/workflows/test.yml |  4 ++--
 test/cider-repl-tests.el   | 29 ++++++++++++++++++++---------
 3 files changed, 32 insertions(+), 12 deletions(-)

diff --git a/.circleci/config.yml b/.circleci/config.yml
index 6a4542a0be..ea36a7402e 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -58,6 +58,14 @@ jobs:
       - setup
       - test
 
+  test-emacs-28:
+    docker:
+      - image: silex/emacs:28-dev
+        entrypoint: bash
+    steps:
+      - setup
+      - test
+
   test-emacs-master:
     docker:
       - image: silex/emacs:master-dev
@@ -78,7 +86,7 @@ jobs:
 
   test-lint:
     docker:
-      - image: silex/emacs:27-dev
+      - image: silex/emacs:28-dev
     steps:
       - setup
       - lint
@@ -89,6 +97,7 @@ workflows:
     jobs:
       - test-emacs-26
       - test-emacs-27
+      - test-emacs-28
       - test-emacs-master
       - test-lint
       - test-windows-emacs-latest
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 9afcc21b1d..6dbf5d833c 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -9,7 +9,7 @@ jobs:
     strategy:
       matrix:
         os: [macos-latest]
-        emacs_version: ['26.3', '27.2']
+        emacs_version: ['26.3', '27.2', '28.1']
 
     steps:
     - name: Set up Emacs
@@ -18,7 +18,7 @@ jobs:
         version: ${{matrix.emacs_version}}
 
     - name: Install Eldev
-      run: curl -fsSL 
https://raw.githubusercontent.com/doublep/eldev/0.10.3/webinstall/github-eldev 
| sh
+      run: curl -fsSL 
https://raw.github.com/doublep/eldev/master/webinstall/github-eldev | sh
 
     - name: Check out the source code
       uses: actions/checkout@v2
diff --git a/test/cider-repl-tests.el b/test/cider-repl-tests.el
index 2fcfbfe77e..dcd56d73ca 100644
--- a/test/cider-repl-tests.el
+++ b/test/cider-repl-tests.el
@@ -97,6 +97,17 @@
           (ansi-color-map (ansi-color-make-color-map)))
      ,@body))
 
+(defmacro text-property-make (foreground-color &optional style)
+  "Return FOREGROUND-COLOR and STYLE as a text property list."
+  (if (< emacs-major-version 28)
+      (if style
+          `(quote ((foreground-color . ,foreground-color) ,style))
+        `(quote (foreground-color . ,foreground-color)))
+    (if style
+        `(quote  (,(intern (concat  "ansi-color-" (symbol-name style)))
+                  (:foreground ,foreground-color)))
+      `(quote  (:foreground ,foreground-color)))))
+
 (describe "multiple calls to cider-repl--emit-output"
   (it "Multiple emit output calls set properties and emit text"
     (with-temp-buffer
@@ -136,25 +147,25 @@
         (expect (buffer-substring-no-properties (point-min) (point-max))
                 :to-equal "a\nb\nc\nd\ne\nf\ng\nh\ni\nj\n")
         (expect (get-text-property 1 'font-lock-face)
-                :to-equal '(foreground-color . "black"))
+                :to-equal (text-property-make "black"))
         (expect (get-text-property 3 'font-lock-face)
                 :to-equal 'cider-repl-stdout-face)
         (expect (get-text-property 5 'font-lock-face)
-                :to-equal '(foreground-color . "red3"))
+                :to-equal (text-property-make "red3"))
         (expect (get-text-property 7 'font-lock-face)
-                :to-equal '(foreground-color . "green3"))
+                :to-equal (text-property-make "green3"))
         (expect (get-text-property 9 'font-lock-face)
-                :to-equal '(foreground-color . "yellow3"))
+                :to-equal (text-property-make "yellow3"))
         (expect (get-text-property 11 'font-lock-face)
-                :to-equal '(foreground-color . "red3"))
+                :to-equal (text-property-make "red3"))
         (expect (get-text-property 13 'font-lock-face)
-                :to-equal '(foreground-color . "green3"))
+                :to-equal (text-property-make "green3"))
         (expect (get-text-property 15 'font-lock-face)
-                :to-equal '((foreground-color . "yellow3") bold))
+                :to-equal (text-property-make "yellow3" bold))
         (expect (get-text-property 17 'font-lock-face)
-                :to-equal '(foreground-color . "red3"))
+                :to-equal (text-property-make "red3"))
         (expect (get-text-property 19 'font-lock-face)
-                :to-equal '((foreground-color . "green3") italic))
+                :to-equal (text-property-make "green3" italic))
         ))))
 
 (defun simulate-cider-output (s property)

Reply via email to