Commit graph

8 commits

Author SHA1 Message Date
Naïm Favier f677cbabe9
nixos/tests: remove minimal-kernel module
It's not used, doesn't build, and seems like the only reason to have
`manualConfig` take `stdenv` as an argument.
2022-12-22 01:42:15 +01:00
Robert Hensing 1d9b913088 nixos/lib/testing: Delay nodes.machine.~config~ migration
Provide a window during which both solutions are valid without
warnings, in order to fight warning fatigue, and not to push 3rd
party repo maintainers to add unnecessary compat code.
2022-10-16 16:30:21 +02:00
Robert Hensing 216c5dc10d nixos/doc: Disambiguate test option ids
Changing this later on would break external links into the manual.
2022-09-29 12:41:59 +02:00
Robert Hensing 1c0b9c4a48 nixos/testing/network.nix: Add network config to specialisations 2022-09-24 17:42:52 +01:00
Robert Hensing 666e969da0 nixos/testing: Add nodes.config backcompat to nodes module argument 2022-09-24 17:38:10 +01:00
Robert Hensing 6205d37747 nixos/testing: Improve option docs 2022-09-24 17:38:10 +01:00
Robert Hensing 24d1d74e4e nixos/testing: Extract nixos-test-base.nix NixOS module 2022-09-24 17:38:09 +01:00
Robert Hensing b3de22483c nixos/testing-python.nix: Add evalTest
This is a decomposition of the testing-python.nix and build-vms.nix
files into modules.

By refactoring the glue, we accomplish the following:

 - NixOS tests can now use `imports` and other module system features.
    - Network-wide test setup can now be reusable; example:
       - A setup with all VMs configured to use a DNS server
       - Split long, slow tests into multiple tests that import a
         common module that has most of the setup.
    - Type checking for the test arguments
    - (TBD) "generated" options reference docs
 - Aspects that had to be wired through all the glue are now in their
   own files.
    - Chief example: interactive.nix.
    - Also: network.nix

In rewriting this, I've generally stuck as close as possible to the
existing code; copying pieces of logic and rewiring them, without
changing the logic itself.

I've made two exceptions to this rule

 - Introduction of `extraDriverArgs` instead of hardcoded
   interactivity logic.

 - Incorporation of https://github.com/NixOS/nixpkgs/pull/144110
   in testScript.nix.

I might revert the latter and split it into a new commit.
2022-09-21 10:55:11 +01:00