summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-03-08 22:21:31 +0100
committerLudovic Courtès <ludo@gnu.org>2017-03-08 23:42:53 +0100
commit1062063a65036f32a061c54866d33ffe079ec44e (patch)
tree99353fb630fadaa654d3cdb856669b878a098a26 /tests
parent30906825cb99122f6b068a1d9223937757d75ce5 (diff)
ui: Don't use '%default-port-encoding' to set the encoding of string ports.
* guix/ui.scm (right-arrow): Call 'set-port-encoding!' to set PORT's encoding; remove use of 'with-fluids'. This is for compatibility with Guile 2.2 where the encoding of string ports is not influenced by %DEFAULT-PORT-ENCODING. * tests/ui.scm ("show-manifest-transaction"): Likewise.
Diffstat (limited to 'tests')
-rw-r--r--tests/ui.scm11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/ui.scm b/tests/ui.scm
index 058207e8b9..cfe417d497 100644
--- a/tests/ui.scm
+++ b/tests/ui.scm
@@ -248,9 +248,12 @@ Second line" 24))
(lambda ()
(show-manifest-transaction store m t)))))
(string-match "guile\t1.8.8 -> 2.0.9"
- (with-fluids ((%default-port-encoding "ISO-8859-1"))
- (with-error-to-string
- (lambda ()
- (show-manifest-transaction store m t)))))))))
+ (with-error-to-string
+ (lambda ()
+ ;; In Guile 2.2, %DEFAULT-PORT-ENCODING doesn't
+ ;; influence the encoding of string ports.
+ (set-port-encoding! (current-error-port)
+ "ISO-8859-1")
+ (show-manifest-transaction store m t))))))))
(test-end "ui")