nixpkgs/nixos/lib/testing/interactive.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
641 B
Nix
Raw Normal View History

{ config, lib, moduleType, hostPkgs, ... }:
let
2022-06-27 20:06:30 +02:00
inherit (lib) mkOption types mdDoc;
in
{
options = {
interactive = mkOption {
2022-06-27 20:06:30 +02:00
description = mdDoc ''
Tests [can be run interactively](#sec-running-nixos-tests-interactively).
When they are, the configuration will include anything set in this submodule.
You can set any top-level test option here.
'';
type = moduleType;
2022-06-27 20:06:30 +02:00
visible = "shallow";
};
};
config = {
interactive.qemu.package = hostPkgs.qemu;
interactive.extraDriverArgs = [ "--interactive" ];
passthru.driverInteractive = config.interactive.driver;
};
}