Skip to content

Commit 57a5edf

Browse files
tests/session: Add a new test
* tests/session.scm ("make-session: keywords must overwrite config options"): New test.
1 parent b694eac commit 57a5edf

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

tests/session.scm

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
;;; session.scm -- Testing of session procedures without a connection.
22

3-
;; Copyright (C) 2014, 2015, 2016, 2017, 2018, 2019, 2020 Artyom V. Poptsov <poptsov.artyom@gmail.com>
3+
;; Copyright (C) 2014-2024 Artyom V. Poptsov <poptsov.artyom@gmail.com>
44
;;
55
;; This file is a part of Guile-SSH.
66
;;
@@ -224,6 +224,14 @@
224224
'guile-ssh-error
225225
(make-session #:config %config))
226226

227+
(test-equal "make-session: keywords must overwrite config options"
228+
22
229+
(let ((s (make-session #:host "localhost"
230+
#:port 22
231+
;; Configuration sets port to 2222
232+
#:config %config)))
233+
(session-get s 'port)))
234+
227235
(test-equal-with-log "blocking-flush!"
228236
'ok
229237
(blocking-flush! (%make-session) 15))

0 commit comments

Comments
 (0)