From 48601269a94456ae61b187ab48e5ba2d98d2ea0b Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 21 May 2014 14:05:43 +0200 Subject: [PATCH] test-driver: Set context to include machines created by createMachine --- nixos/lib/test-driver/test-driver.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/lib/test-driver/test-driver.pl b/nixos/lib/test-driver/test-driver.pl index 358c29e515f2..8ad0d67f68c3 100644 --- a/nixos/lib/test-driver/test-driver.pl +++ b/nixos/lib/test-driver/test-driver.pl @@ -52,12 +52,12 @@ sub createMachine { my ($args) = @_; my $vm = Machine->new({%{$args}, log => $log, redirectSerial => ($ENV{USE_SERIAL} // "0") ne "1"}); $vms{$vm->name} = $vm; + $context .= "my \$" . $vm->name . " = \$vms{'" . $vm->name . "'}; "; return $vm; } foreach my $vmScript (@ARGV) { my $vm = createMachine({startCommand => $vmScript}); - $context .= "my \$" . $vm->name . " = \$vms{'" . $vm->name . "'}; "; }