2022-09-30 11:47:45 +00:00
|
|
|
{ config, options, lib, ... }:
|
|
|
|
let
|
|
|
|
inherit (lib) mkIf mkOption types;
|
|
|
|
in
|
|
|
|
{
|
2022-12-28 21:21:41 +00:00
|
|
|
# This needs options.warnings and options.assertions, which we don't have (yet?).
|
2022-09-30 11:47:45 +00:00
|
|
|
# imports = [
|
|
|
|
# (lib.mkRenamedOptionModule [ "machine" ] [ "nodes" "machine" ])
|
2022-12-28 21:21:41 +00:00
|
|
|
# (lib.mkRemovedOptionModule [ "minimal" ] "The minimal kernel module was removed as it was broken and not used any more in nixpkgs.")
|
2022-09-30 11:47:45 +00:00
|
|
|
# ];
|
|
|
|
|
|
|
|
options = {
|
|
|
|
machine = mkOption {
|
|
|
|
internal = true;
|
|
|
|
type = types.raw;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
config = {
|
|
|
|
nodes = mkIf options.machine.isDefined (
|
|
|
|
lib.warn
|
|
|
|
"In test `${config.name}': The `machine' attribute in NixOS tests (pkgs.nixosTest / make-test-python.nix / testing-python.nix / makeTest) is deprecated. Please set the equivalent `nodes.machine'."
|
|
|
|
{ inherit (config) machine; }
|
|
|
|
);
|
|
|
|
};
|
|
|
|
}
|