From fd4885528445b94aea7dd15a09bee85c2bc1defe Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 12 Jan 2011 17:36:15 +0000 Subject: [PATCH] * No wonder the OpenSSH test was so unreliable: it didn't wait for the sshd Upstart job to finish. svn path=/nixos/trunk/; revision=25524 --- tests/openssh.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/tests/openssh.nix b/tests/openssh.nix index ca96e6ccfc9b..1c93f8a3b417 100644 --- a/tests/openssh.nix +++ b/tests/openssh.nix @@ -1,25 +1,26 @@ -{pkgs, ...}: +{ pkgs, ... }: { nodes = { server = - {pkgs, config, ...}: + { config, pkgs, ... }: { services.openssh.enable = true; }; client = - {pkgs, config, ...}: + { config, pkgs, ... }: { }; - { - }; }; - testScript = - '' + testScript = '' + startAll; + my $key=`${pkgs.openssh}/bin/ssh-keygen -t dsa -f key -N ""`; + + $server->waitForJob("sshd"); $server->mustSucceed("mkdir -m 700 /root/.ssh"); $server->copyFileFromHost("key.pub", "/root/.ssh/authorized_keys");