From 18ef97dcae8dd2b8af2dc905e11d2dbd3e452a06 Mon Sep 17 00:00:00 2001 From: Matěj Cepl Date: Sat, 25 Nov 2023 20:00:56 +0100 Subject: Move everything irrelevant to _attic/. It was too confusing for newcomers to look at the stuff which is just a note from the old project. --- tests/pinentry-rofi.bats | 457 ----------------------------------------------- 1 file changed, 457 deletions(-) delete mode 100755 tests/pinentry-rofi.bats (limited to 'tests') diff --git a/tests/pinentry-rofi.bats b/tests/pinentry-rofi.bats deleted file mode 100755 index 8c7748e..0000000 --- a/tests/pinentry-rofi.bats +++ /dev/null @@ -1,457 +0,0 @@ -#!/usr/bin/env bats - -## (define-module (tests-pinentry-rofi) -## #:use-module (srfi srfi-64) -## #:use-module (ice-9 popen) -## #:use-module (ice-9 textual-ports) -## #:use-module (pinentry-rofi)) - -# XXX (test-begin "pinentry-rofi") - -# XXX ;; (test-begin "pinentry") -# XXX (let ((pinentry (make-pinentry #t "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry? pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-equal "Prompt" (pinentry-prompt pinentry)) -# XXX (test-equal "Ok" (pinentry-ok-button pinentry)) -# XXX (test-equal "Cancel" (pinentry-cancel-button pinentry)) -# XXX (test-equal ":1" (pinentry-display pinentry)) -# XXX (test-equal "test.log" (pinentry-logfile pinentry)) -# XXX (test-assert (not (pinentry-notok-button pinentry))) -# XXX (test-assert (not (pinentry-visibility pinentry))) -# XXX (test-assert (not (pinentry-error pinentry)))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (not (pinentry-ok pinentry)))) -# XXX -# XXX ;; (test-end "pinentry") -# XXX -# XXX ;; (test-begin "utils") -# XXX -# XXX (test-equal "Ok" (remove-underline "_Ok")) -# XXX (test-equal " Ok" (remove-underline " _Ok")) -# XXX (test-equal "foo_bar" (remove-underline "foo_bar")) -# XXX (test-equal "foo__bar" (remove-underline "foo__bar")) -# XXX (test-equal " __Ok" (remove-underline " __Ok")) -# XXX (test-equal "__Ok" (remove-underline "__Ok")) -# XXX (test-equal "Ok%0ACancel" (remove-underline "_Ok%0A_Cancel")) -# XXX (test-equal "Ok Cancel" (remove-underline "_Ok _Cancel")) -# XXX -# XXX (test-equal "_Ok" (escape-underscore "_Ok")) -# XXX (test-equal " _Ok" (escape-underscore " _Ok")) -# XXX (test-equal "foo_bar" (escape-underscore "foo_bar")) -# XXX (test-equal "foo__bar" (escape-underscore "foo__bar")) -# XXX (test-equal " _Ok" (escape-underscore " __Ok")) -# XXX (test-equal "_Ok" (escape-underscore "__Ok")) -# XXX (test-equal "_Ok%0A_Cancel" (escape-underscore "__Ok%0A__Cancel")) -# XXX (test-equal "_Ok _Cancel" (escape-underscore "__Ok __Cancel")) -# XXX -# XXX (test-assert (string-empty? "")) -# XXX (test-assert (not (string-empty? "foo"))) -# XXX ;; (test-end "utils") -# XXX -# XXX (test-equal "This is one line\nThis is another%OA" -# XXX (hex->char "%54his is one line%0AThis is another%OA")) -# XXX -# XXX ;; (test-begin "html") -# XXX (test-equal "%54his is one line This is another%OA" -# XXX (html-newline "%54his is one line%0AThis is another%OA")) -# XXX (test-equal "%54his is one line\nThis is another%OA" -# XXX (html-newline "%54his is one line\nThis is another%OA")) -# XXX -# XXX (test-equal "Ok" (html-underline "_Ok")) -# XXX (test-equal " Ok" (html-underline " _Ok")) -# XXX (test-equal "foo_bar" (html-underline "foo_bar")) -# XXX (test-equal "foo__bar" (html-underline "foo__bar")) -# XXX (test-equal " __Ok" (html-underline " __Ok")) -# XXX (test-equal "__Ok" (html-underline "__Ok")) -# XXX (test-equal "Ok%0ACancel" (html-underline "_Ok%0A_Cancel")) -# XXX (test-equal "Ok Cancel" (html-underline "_Ok _Cancel")) -# XXX -# XXX ;; (test-end "html") -# XXX -# XXX (test-equal "This is one line This is another%OA" -# XXX (pango-markup "_%54his is one line%0A_This is another%OA")) -# XXX -# XXX (test-equal "Ok\nCancel" -# XXX (input-string "_Ok\nCancel")) -# XXX -# XXX (test-equal "Ok\n_Cancel" -# XXX (input-string "_Ok\n__Cancel")) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (pinentry-set set-pinentry-notok-button! pinentry "Not ok") -# XXX (test-equal "Not ok" (pinentry-notok-button pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-error #t (pinentry-set pinentry-notok-button pinentry "Not ok"))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION default-ok=Okay")) -# XXX (test-equal "Okay" (pinentry-ok-button pinentry)) -# XXX (test-equal "Cancel" (pinentry-cancel-button pinentry)) -# XXX (test-equal "Prompt" (pinentry-prompt pinentry)) -# XXX (test-equal "C" (pinentry-lc-ctype pinentry)) -# XXX (test-equal "C" (pinentry-lc-messages pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION default-cancel=No")) -# XXX (test-equal "Ok" (pinentry-ok-button pinentry)) -# XXX (test-equal "No" (pinentry-cancel-button pinentry)) -# XXX (test-equal "Prompt" (pinentry-prompt pinentry)) -# XXX (test-equal "C" (pinentry-lc-ctype pinentry)) -# XXX (test-equal "C" (pinentry-lc-messages pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION default-prompt=Password:")) -# XXX (test-equal "Ok" (pinentry-ok-button pinentry)) -# XXX (test-equal "Cancel" (pinentry-cancel-button pinentry)) -# XXX (test-equal "Password:" (pinentry-prompt pinentry)) -# XXX (test-equal "C" (pinentry-lc-ctype pinentry)) -# XXX (test-equal "C" (pinentry-lc-messages pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION lc-ctype=en_US.UTF-8")) -# XXX (test-equal "Ok" (pinentry-ok-button pinentry)) -# XXX (test-equal "Cancel" (pinentry-cancel-button pinentry)) -# XXX (test-equal "Prompt" (pinentry-prompt pinentry)) -# XXX (test-equal "en_US.UTF-8" (pinentry-lc-ctype pinentry)) -# XXX (test-equal "C" (pinentry-lc-messages pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION lc-messages=en_US.UTF-8")) -# XXX (test-equal "Ok" (pinentry-ok-button pinentry)) -# XXX (test-equal "Cancel" (pinentry-cancel-button pinentry)) -# XXX (test-equal "Prompt" (pinentry-prompt pinentry)) -# XXX (test-equal "C" (pinentry-lc-ctype pinentry)) -# XXX (test-equal "en_US.UTF-8" (pinentry-lc-messages pinentry)) -# XXX (test-assert (pinentry-ok pinentry))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-option pinentry "OPTION foo bar"))) -# XXX -# XXX (let ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (not (pinentry-option pinentry " OPTION foo bar"))) -# XXX (test-assert (not (pinentry-option pinentry "OPTION"))) -# XXX (test-assert (not (pinentry-option pinentry "Foo")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C")) -# XXX (output "") -# XXX (fake-port (make-soft-port -# XXX (vector -# XXX (lambda (c) (set! output (string-append output c))) -# XXX (lambda (s) (set! output (string-append output s))) -# XXX (lambda () #t) -# XXX #f -# XXX (lambda () #t)) -# XXX "w"))) -# XXX (test-assert (pinentry-getinfo pinentry "GETINFO pid" #:port fake-port)) -# XXX (test-equal (format #f "D ~a\n" (getpid)) output) -# XXX (test-assert (pinentry-getinfo pinentry "GETINFO foo bar")) -# XXX (test-assert (not (pinentry-getinfo pinentry " GETINFO foo bar"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "GETINFO"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "Foo")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setkeyinfo pinentry "SETKEYINFO Foo")) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (not (pinentry-setkeyinfo pinentry " SETKEYINFO foo bar"))) -# XXX (test-assert (not (pinentry-setkeyinfo pinentry "SETKEYINFO"))) -# XXX (test-assert (not (pinentry-setkeyinfo pinentry "Foo")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setok pinentry "SETOK Foo")) -# XXX (test-equal "Foo" (pinentry-ok-button pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-setok pinentry "SETOK _Ok okay")) -# XXX (test-equal "Ok okay" (pinentry-ok-button pinentry)) -# XXX (test-assert (not (pinentry-setok pinentry " SETOK foo bar"))) -# XXX (test-equal "Ok okay" (pinentry-ok-button pinentry)) -# XXX (test-assert (not (pinentry-setok pinentry "SETOK"))) -# XXX (test-equal "Ok okay" (pinentry-ok-button pinentry)) -# XXX (test-assert (not (pinentry-setok pinentry "Foo"))) -# XXX (test-equal "Ok okay" (pinentry-ok-button pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setnotok pinentry "SETNOTOK Foo")) -# XXX (test-equal "Foo" (pinentry-notok-button pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-setnotok pinentry "SETNOTOK Not _Ok")) -# XXX (test-equal "Not Ok" (pinentry-notok-button pinentry)) -# XXX (test-assert (not (pinentry-setnotok pinentry " SETNOTOK foo bar"))) -# XXX (test-equal "Not Ok" (pinentry-notok-button pinentry)) -# XXX (test-assert (not (pinentry-setnotok pinentry "SETNOTOK"))) -# XXX (test-equal "Not Ok" (pinentry-notok-button pinentry)) -# XXX (test-assert (not (pinentry-setnotok pinentry "Foo"))) -# XXX (test-equal "Not Ok" (pinentry-notok-button pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setcancel pinentry "SETCANCEL Foo")) -# XXX (test-equal "Foo" (pinentry-cancel-button pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-setcancel pinentry "SETCANCEL _Abort")) -# XXX (test-equal "Abort" (pinentry-cancel-button pinentry)) -# XXX (test-assert (not (pinentry-setcancel pinentry " SETCANCEL foo bar"))) -# XXX (test-equal "Abort" (pinentry-cancel-button pinentry)) -# XXX (test-assert (not (pinentry-setcancel pinentry "SETCANCEL"))) -# XXX (test-equal "Abort" (pinentry-cancel-button pinentry)) -# XXX (test-assert (not (pinentry-setcancel pinentry "Foo"))) -# XXX (test-equal "Abort" (pinentry-cancel-button pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Desc" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setdesc pinentry "SETDESC Foo")) -# XXX (test-equal "Foo" (pinentry-desc pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-setdesc pinentry "SETDESC _%54his is a description%0A_On two lines")) -# XXX (test-equal "This is a description On two lines" (pinentry-desc pinentry)) -# XXX (test-assert (not (pinentry-setdesc pinentry " SETDESC foo bar"))) -# XXX (test-equal "This is a description On two lines" (pinentry-desc pinentry)) -# XXX (test-assert (not (pinentry-setdesc pinentry "SETDESC"))) -# XXX (test-equal "This is a description On two lines" (pinentry-desc pinentry)) -# XXX (test-assert (not (pinentry-setdesc pinentry "Foo"))) -# XXX (test-equal "This is a description On two lines" (pinentry-desc pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Error" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-seterror pinentry "SETERROR Foo")) -# XXX (test-equal "Foo" (pinentry-error pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-seterror pinentry "SETERROR _%54his is an error%0A_On two lines")) -# XXX (test-equal "This is an error On two lines" (pinentry-error pinentry)) -# XXX (test-assert (not (pinentry-seterror pinentry " SETERROR foo bar"))) -# XXX (test-equal "This is an error On two lines" (pinentry-error pinentry)) -# XXX (test-assert (not (pinentry-seterror pinentry "SETERROR"))) -# XXX (test-equal "This is an error On two lines" (pinentry-error pinentry)) -# XXX (test-assert (not (pinentry-seterror pinentry "Foo"))) -# XXX (test-equal "This is an error On two lines" (pinentry-error pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Prompt" ":1" "test.log" "C" "C"))) -# XXX (test-assert (pinentry-setprompt pinentry "SETPROMPT Foo")) -# XXX (test-equal "Foo" (pinentry-prompt pinentry)) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (pinentry-setprompt pinentry "SETPROMPT _%54his is a prompt%0A_On two lines")) -# XXX (test-equal "This is a prompt On two lines" (pinentry-prompt pinentry)) -# XXX (test-assert (not (pinentry-setprompt pinentry " SETPROMPT foo bar"))) -# XXX (test-equal "This is a prompt On two lines" (pinentry-prompt pinentry)) -# XXX (test-assert (not (pinentry-setprompt pinentry "SETPROMPT"))) -# XXX (test-equal "This is a prompt On two lines" (pinentry-prompt pinentry)) -# XXX (test-assert (not (pinentry-setprompt pinentry "Foo"))) -# XXX (test-equal "This is a prompt On two lines" (pinentry-prompt pinentry))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Prompt" ":1" "test.log" "C" "C"))) -# XXX (test-error "(quit #t)" (pinentry-bye pinentry "BYE")) -# XXX (test-assert (not (pinentry-bye pinentry "Hej då")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "en_US.UTF-8")) -# XXX (output "") -# XXX (fake-port (make-soft-port -# XXX (vector -# XXX (lambda (c) (set! output (string-append output c))) -# XXX (lambda (s) (set! output (string-append output s))) -# XXX (lambda () #t) -# XXX #f -# XXX (lambda () #t)) -# XXX "w")) -# XXX (description "This is a description") -# XXX (error "Something went wrong") -# XXX (display ":1")) -# XXX (set-pinentry-desc! pinentry description) -# XXX (set-pinentry-display! pinentry display) -# XXX (test-assert (pinentry-getpin pinentry "GETPIN" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal "Prompt" prompt) -# XXX (test-equal description message) -# XXX (test-assert (not visibility)) -# XXX (test-assert (not only-match)) -# XXX (test-assert (not buttons)) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "password") -# XXX #:port fake-port)) -# XXX (test-equal (format #f "D password") output) -# XXX (set-pinentry-error! pinentry error) -# XXX (set! output "") -# XXX (test-assert (pinentry-getpin pinentry "GETPIN" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal "Prompt" prompt) -# XXX (test-equal (format #f "~a ~a" error description) -# XXX message) -# XXX (test-assert (not visibility)) -# XXX (test-assert (not only-match)) -# XXX (test-assert (not buttons)) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "password") -# XXX #:port fake-port)) -# XXX (test-equal (format #f "D password") output) -# XXX (set! output "") -# XXX (test-assert (pinentry-getpin pinentry "GETPIN" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal "Prompt" prompt) -# XXX (test-equal (format #f "~a ~a" error description) -# XXX message) -# XXX (test-assert (not visibility)) -# XXX (test-assert (not only-match)) -# XXX (test-assert (not buttons)) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "") -# XXX #:port fake-port)) -# XXX (test-equal (format #f "ERR 83886179 Operation cancelled \n") output) -# XXX (set! output "") -# XXX (test-assert (pinentry-getpin pinentry "GETPIN" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal "Prompt" prompt) -# XXX (test-equal (format #f "~a ~a" error description) -# XXX message) -# XXX (test-assert (not visibility)) -# XXX (test-assert (not only-match)) -# XXX (test-assert (not buttons)) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX " ") -# XXX #:port fake-port)) -# XXX (test-equal (format #f "ERR 83886179 Operation cancelled \n") output) -# XXX (test-assert (not (pinentry-getinfo pinentry " GETPIN"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "Foo")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "en_US.UTF-8")) -# XXX (description "This is a description") -# XXX (error "Something went wrong") -# XXX (display ":1")) -# XXX (set-pinentry-desc! pinentry description) -# XXX (set-pinentry-display! pinentry display) -# XXX (test-assert (pinentry-confirm pinentry "CONFIRM" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal ">" prompt) -# XXX (test-equal description message) -# XXX (test-assert visibility) -# XXX (test-assert only-match) -# XXX (test-equal `("Ok" "Cancel") buttons) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "Ok"))) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (set-pinentry-error! pinentry error) -# XXX (let* ((output "") -# XXX (fake-port (make-soft-port -# XXX (vector -# XXX (lambda (c) (set! output (string-append output c))) -# XXX (lambda (s) (set! output (string-append output s))) -# XXX (lambda () #t) -# XXX #f -# XXX (lambda () #t)) -# XXX "w"))) -# XXX (test-assert (pinentry-confirm -# XXX pinentry -# XXX "CONFIRM" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal ">" prompt) -# XXX (test-equal (format #f "~a ~a" error description) -# XXX message) -# XXX (test-assert visibility) -# XXX (test-assert only-match) -# XXX (test-equal `("Ok" "Cancel") buttons) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "Cancel") -# XXX #:port fake-port)) -# XXX (test-equal (format #f "ERR 277 Operation cancelled\n") output)) -# XXX (test-assert (not (pinentry-ok pinentry))) -# XXX (test-assert (not (pinentry-getinfo pinentry " CONFIRM"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "Foo")))) -# XXX -# XXX (let* ((pinentry (make-pinentry #f "Prompt" "Ok" "Cancel" ":1" "test.log" "C" "en_US.UTF-8")) -# XXX (description "This is a description") -# XXX (display ":1")) -# XXX (set-pinentry-desc! pinentry description) -# XXX (set-pinentry-display! pinentry display) -# XXX (test-assert (pinentry-confirm pinentry "CONFIRM --one-button" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal ">" prompt) -# XXX (test-equal description message) -# XXX (test-assert visibility) -# XXX (test-assert only-match) -# XXX (test-equal `("Ok") buttons) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "Ok"))) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (set-pinentry-ok! pinentry #f) -# XXX (test-assert (pinentry-confirm pinentry "MESSAGE" -# XXX (lambda* (#:key (env '()) -# XXX visibility -# XXX (prompt ">") -# XXX message -# XXX buttons -# XXX only-match) -# XXX (test-equal ">" prompt) -# XXX (test-equal description message) -# XXX (test-assert visibility) -# XXX (test-assert only-match) -# XXX (test-equal `("Ok") buttons) -# XXX (test-equal `(("DISPLAY" . ,display) -# XXX ("LC_CTYPE" . "C") -# XXX ("LC_MESSAGES" . "en_US.UTF-8")) -# XXX env) -# XXX "Ok"))) -# XXX (test-assert (pinentry-ok pinentry)) -# XXX (test-assert (not (pinentry-getinfo pinentry " CONFIRM --one-button"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "MESSAGE --one-button"))) -# XXX (test-assert (not (pinentry-getinfo pinentry " MESSAGE"))) -# XXX (test-assert (not (pinentry-getinfo pinentry "Foo")))) -# XXX -# XXX (test-end "pinentry-rofi") -- cgit