anchor.diff:        $machine->succeed("cat /mnt/etc/nixos/hardware-configuration.nix >&2");
   
         $machine->copyFileFromHost(
  -          "${ makeConfig { inherit testChannel grubVersion grubDevice grubIdentifier; } }",
  +          "${ makeConfig { inherit testChannel grubVersion grubDevice grubIdentifier extraConfig; } }",
             "/mnt/etc/nixos/configuration.nix");
   
         # Perform the installation.
  
positive.code:   # disk, and then reboot from the hard disk.  It's parameterized with
    # a test script fragment `createPartitions', which must create
    # partitions and filesystems.
    testScriptFun = { createPartitions, testChannel, grubVersion, grubDevice, grubIdentifier }:
      let
        # FIXME: OVMF doesn't boot from virtio http://www.mail-archive.com/edk2-devel@lists.sourceforge.net/msg01501.html
        iface = if grubVersion == 1 then "scsi" else "virtio";
  
negative.code: 
    # The configuration to install.
    makeConfig = { testChannel, grubVersion, grubDevice, grubIdentifier
                 , extraConfig, readOnly ? true, forceGrubReinstallCount ? 0
                 }:
      pkgs.writeText "configuration.nix" ''
        { config, lib, pkgs, modulesPath, ... }:
  
  