[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/compat fc2ad0899d 6/7: Test buffer-local-boundp
From: |
ELPA Syncer |
Subject: |
[elpa] externals/compat fc2ad0899d 6/7: Test buffer-local-boundp |
Date: |
Wed, 4 Jan 2023 13:57:28 -0500 (EST) |
branch: externals/compat
commit fc2ad0899d695596026278992ad25b8fa753ace1
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Test buffer-local-boundp
---
compat-28.el | 2 +-
compat-tests.el | 11 +++++++++++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/compat-28.el b/compat-28.el
index 2e0d8e6b75..4ab40da69b 100644
--- a/compat-28.el
+++ b/compat-28.el
@@ -384,7 +384,7 @@ REPLACEMENT can use the following special elements:
(and (not (zerop matches))
matches))))
-(compat-defun buffer-local-boundp (symbol buffer) ;; <UNTESTED>
+(compat-defun buffer-local-boundp (symbol buffer) ;; <OK>
"Return non-nil if SYMBOL is bound in BUFFER.
Also see `local-variable-p'."
(catch 'fail
diff --git a/compat-tests.el b/compat-tests.el
index 41e25bc5fb..5334e3de62 100644
--- a/compat-tests.el
+++ b/compat-tests.el
@@ -89,6 +89,17 @@
(ert-deftest format-message ()
(should-equal (format-message "a=%s b=%s" 1 2) "a=1 b=2"))
+(defvar test-boundp)
+(defvar test-global-boundp)
+(ert-deftest buffer-local-boundp ()
+ (let ((buf (generate-new-buffer "boundp")))
+ (with-current-buffer buf
+ (setq-local test-boundp t))
+ (setq test-global-boundp t)
+ (should (buffer-local-boundp 'test-boundp buf))
+ (should-not (buffer-local-boundp 'test-not-boundp buf))
+ (should (buffer-local-boundp 'test-global-boundp buf))))
+
(defvar compat-local-a nil)
(defvar compat-local-b nil)
(defvar compat-local-c nil)
- [elpa] externals/compat updated (8144719780 -> f0362f354c), ELPA Syncer, 2023/01/04
- [elpa] externals/compat 8ab4272a5d 5/7: Add thread-first and thread-last tests, ELPA Syncer, 2023/01/04
- [elpa] externals/compat 9257871cb0 3/7: Test take and ntake, ELPA Syncer, 2023/01/04
- [elpa] externals/compat 01ed1c6737 1/7: Drop broken func-arity, ELPA Syncer, 2023/01/04
- [elpa] externals/compat f0362f354c 7/7: Warn about untested functions, ELPA Syncer, 2023/01/04
- [elpa] externals/compat fc2ad0899d 6/7: Test buffer-local-boundp,
ELPA Syncer <=
- [elpa] externals/compat b126fd50df 2/7: Mark a few functions as tested, ELPA Syncer, 2023/01/04
- [elpa] externals/compat 1d25236892 4/7: Use with-eval-after-load (24.4), ELPA Syncer, 2023/01/04