(defvar dbus-message-type-method-return)
(defvar dbus-message-type-error)
(defvar dbus-message-type-signal)
-(defvar dbus-debug)
(defvar dbus-registered-objects-table)
+;; The following symbols are defined in dbusbind.c. We need them also
+;; when Emacs is compiled without D-Bus support.
+(unless (boundp 'dbus-error)
+ (define-error 'dbus-error "D-Bus error"))
+
+(unless (boundp 'dbus-debug)
+ (defvar dbus-debug nil))
+
;; Pacify byte compiler.
(eval-when-compile (require 'cl-lib))
;;; Code:
(require 'ert)
-(when (featurep 'dbusbind) (require 'secrets))
+(require 'secrets)
(require 'notifications)
;; We do not want chatty messages.
(ert-deftest secrets-test00-availability ()
"Test availability of Secret Service API."
- (skip-unless (featurep 'dbusbind))
:expected-result (if secrets-enabled :passed :failed)
(should secrets-enabled)
(should (dbus-ping :session secrets-service))
(ert-deftest secrets-test01-sessions ()
"Test opening / closing a secrets session."
- (skip-unless (featurep 'dbusbind))
(skip-unless secrets-enabled)
(skip-unless (secrets-empty-path secrets-session-path))
(ert-deftest secrets-test02-collections ()
"Test creation / deletion a secrets collections."
- (skip-unless (featurep 'dbusbind))
(skip-unless secrets-enabled)
(skip-unless (secrets-empty-path secrets-session-path))
(ert-deftest secrets-test03-items ()
"Test creation / deletion a secret item."
- (skip-unless (featurep 'dbusbind))
(skip-unless secrets-enabled)
(skip-unless (secrets-empty-path secrets-session-path))
(ert-deftest secrets-test04-search ()
"Test searching of secret items."
- (skip-unless (featurep 'dbusbind))
(skip-unless secrets-enabled)
(skip-unless (secrets-empty-path secrets-session-path))