[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP.
From: |
Clément Lassieur |
Subject: |
bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP. |
Date: |
Tue, 21 Mar 2017 01:03:04 +0100 |
User-agent: |
mu4e 0.9.18; emacs 25.2.1 |
Ludovic Courtès <address@hidden> writes:
> Clément Lassieur <address@hidden> skribis:
>
>> * gnu/tests/ssh.scm (run-ssh-test): Introduce "SFTP file writing and
>> reading".
>> Make 'sftp' a keyword parameter.
>
> Woohoo!
>
> Please also mention the change to ‘%test-openssh’.
>
>> +(define* (run-ssh-test name ssh-service pid-file #:key (sftp #f))
>> "Run a test of an OS running SSH-SERVICE, which writes its PID to
>> PID-FILE.
>> SSH-SERVICE must be configured to listen on port 22 and to allow for root
>> and
>> empty-password logins."
>
> Nitpick: call it ‘sftp?’ (with a question mark) to make it clear it’s a
> Boolean, and mention it in the docstring.
>
>> + ;; Connect to the guest over SFTP. Make sure we can write and
>> + ;; read a file there.
>> + (when #$sftp
>> + (test-equal "SFTP file writing and reading"
>
> You can write it like this:
>
> (unless #$sftp?
> (test-skip 1))
>
> (test-equal …)
>
> That way the test will be marked as skipped when SFTP support is
> missing, which is marginally nicer.
>
> Thanks for taking the time to write this test!
Thank you for the review :)
I'll send an updated patchset.
Clément
- bug#26173: Add an internal SFTP server to the OpenSSH service., Clément Lassieur, 2017/03/19
- bug#26173: [PATCH 1/4] services: openssh: Cosmetic changes., Clément Lassieur, 2017/03/19
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Clément Lassieur, 2017/03/19
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Ludovic Courtès, 2017/03/20
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP.,
Clément Lassieur <=
- bug#26173: [PATCH 1/4] services: openssh: Cosmetic changes., Clément Lassieur, 2017/03/20
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Clément Lassieur, 2017/03/20
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Leo Famulari, 2017/03/20
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Clément Lassieur, 2017/03/21
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Marius Bakke, 2017/03/21
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Leo Famulari, 2017/03/21
- bug#26173: [PATCH 4/4] tests: ssh: Add a test for SFTP., Clément Lassieur, 2017/03/21
- bug#26173: [PATCH 3/4] tests: ssh: Abstract session connection and authentication., Clément Lassieur, 2017/03/20
- bug#26173: [PATCH 2/4] services: openssh: Add 'subsystems' option., Clément Lassieur, 2017/03/20
- bug#26173: [PATCH 2/4] services: openssh: Add 'subsystems' option., Ludovic Courtès, 2017/03/21