branch: elpa/sly
commit 52e96126f6762558a76d031f05b2d3608ed2b105
Author: André A. Gomes <[email protected]>
Commit: André A. Gomes <[email protected]>

    Revert "Try yet again to get stabler indentation tests on Travis"
    
    This reverts commit 4eb819fddb22af6d3a953c282b91b9ed7a2e8762 since Travis 
CI has
    been replaced by GitHub Actions.
---
 lib/sly-tests.el              | 2 +-
 test/sly-indentation-tests.el | 8 +++-----
 2 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/lib/sly-tests.el b/lib/sly-tests.el
index b52f88009b6..106ba27ff4b 100644
--- a/lib/sly-tests.el
+++ b/lib/sly-tests.el
@@ -1081,7 +1081,7 @@ the buffer's undo-list."
     (dolist (marker point-markers)
       (search-backward marker)
       (beginning-of-defun)
-      (indent-region (point) (progn (end-of-defun) (point))))
+      (indent-sexp))
     (sly-test-expect "Correct buffer content"
                        buffer-content
                        (substring-no-properties (buffer-string)))))
diff --git a/test/sly-indentation-tests.el b/test/sly-indentation-tests.el
index 93bfef0a6df..e4a726579b6 100644
--- a/test/sly-indentation-tests.el
+++ b/test/sly-indentation-tests.el
@@ -48,11 +48,9 @@
         (when (string= mess expected)
           (ert-fail "Could not mess up indentation?"))
         (goto-char (point-min))
-        (indent-region (point-min) (point-max)) ;; Used to be
-                                                ;;  ‘indent-sexp’, but
-                                                ;;  was super unstable
-                                                ;;  on travis, for
-                                                ;;  some reason.
+        (if (eq sly-indentation--test-function 'indent-region)
+            (indent-region (point-min) (point-max))
+          (indent-sexp))
         (delete-trailing-whitespace)
         (let ((expected-lines (split-string expected "\n"))
               (observed-lines (split-string (buffer-string) "\n")))

Reply via email to