nixos/tests/taskserver: Make tests less noisy

We were putting the whole output of "nixos-taskserver export-user" from
the server to the respective client and on every such operation the
whole output was shown again in the test log.

Now we're *only* showing these details whenever a user import fails on
the client.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
aszlig 2016-04-12 01:49:47 +02:00
parent 7889fcfa41
commit cfb6ce2abe
No known key found for this signature in database
GPG key ID: D0EBD0EC8C2DC961

View file

@ -50,7 +50,15 @@ import ./make-test.nix {
$exportinfo =~ s/'/'\\'''/g;
$client->succeed(su $user, "eval '$exportinfo' >&2");
$client->nest("importing taskwarrior configuration", sub {
my $cmd = su $user, "eval '$exportinfo' >&2";
my ($status, $out) = $client->execute_($cmd);
if ($status != 0) {
$client->log("output: $out");
die "command `$cmd' did not succeed (exit code $status)\n";
}
});
$client->succeed(su $user,
"task config taskd.server server:${portStr} >&2"
);