Author: eelco
Date: Wed Feb 16 10:07:28 2011
New Revision: 25986
URL: https://svn.nixos.org/websvn/nix/?rev=25986&sc=1

Log:
* Only add a VDE NIC if there is a webserver.

Modified:
   nixos/trunk/lib/test-driver/Machine.pm
   nixos/trunk/tests/installer.nix

Modified: nixos/trunk/lib/test-driver/Machine.pm
==============================================================================
--- nixos/trunk/lib/test-driver/Machine.pm      Wed Feb 16 09:18:07 2011        
(r25985)
+++ nixos/trunk/lib/test-driver/Machine.pm      Wed Feb 16 10:07:28 2011        
(r25986)
@@ -20,7 +20,7 @@
     
     my $name = $args->{name};
     if (!$name) {
-        $startCommand =~ /run-(.*)-vm$/;
+        $startCommand =~ /run-(.*)-vm$/ if defined $startCommand;
         $name = $1 || "machine";
     }
 

Modified: nixos/trunk/tests/installer.nix
==============================================================================
--- nixos/trunk/tests/installer.nix     Wed Feb 16 09:18:07 2011        (r25985)
+++ nixos/trunk/tests/installer.nix     Wed Feb 16 10:07:28 2011        (r25986)
@@ -93,7 +93,8 @@
     ''
       createDisk("harddisk", 4 * 1024);
 
-      my $machine = createMachine({ hda => "harddisk", cdrom => 
glob("${iso}/iso/*.iso"), qemuFlags => '${qemuNICFlags 1 1 1}' });
+      my $machine = createMachine({ hda => "harddisk", cdrom => 
glob("${iso}/iso/*.iso"), 
+        qemuFlags => '${if testChannel then qemuNICFlags 1 1 1 else ""}'});
       $machine->start;
 
       ${optionalString testChannel ''
_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits

Reply via email to