diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/infrastructure/clean.awk | 13 | ||||
| -rw-r--r-- | tests/old/README.md (renamed from tests/README.md) | 16 | ||||
| -rw-r--r-- | tests/old/by-name/le/less/data/test.file (renamed from tests/by-name/le/less/data/test.file) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/le/less/data/test.file.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/le/less/test.desc (renamed from tests/by-name/le/less/test.desc) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/le/less/test.desc.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/le/less/test.nix (renamed from tests/by-name/le/less/test.nix) | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-checkhealth/test.desc (renamed from tests/by-name/nv/nvim-checkhealth/test.desc) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-checkhealth/test.desc.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-checkhealth/test.nix (renamed from tests/by-name/nv/nvim-checkhealth/test.nix) | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/data/index.norg (renamed from tests/by-name/nv/nvim-neorg/data/index.norg) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/data/index.norg.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/data/reference.norg (renamed from tests/by-name/nv/nvim-neorg/data/reference.norg) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/data/reference.norg.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/test.desc (renamed from tests/by-name/nv/nvim-neorg/test.desc) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/test.desc.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/nv/nvim-neorg/test.nix (renamed from tests/by-name/nv/nvim-neorg/test.nix) | 13 | ||||
| -rw-r--r-- | tests/old/by-name/ya/yambar/test.desc (renamed from tests/by-name/ya/yambar/test.desc) | 0 | ||||
| -rw-r--r-- | tests/old/by-name/ya/yambar/test.desc.license | 9 | ||||
| -rw-r--r-- | tests/old/by-name/ya/yambar/test.nix (renamed from tests/by-name/ya/yambar/test.nix) | 9 | ||||
| -rw-r--r-- | tests/old/default.nix (renamed from tests/default.nix) | 9 | ||||
| -rw-r--r-- | tests/old/infrastructure/clean.awk | 23 | ||||
| -rw-r--r-- | tests/old/infrastructure/default.nix (renamed from tests/infrastructure/default.nix) | 11 | ||||
| -rw-r--r-- | tests/old/infrastructure/driver.sh (renamed from tests/infrastructure/driver.sh) | 11 | ||||
| -rw-r--r-- | tests/old/infrastructure/run.nix (renamed from tests/infrastructure/run.nix) | 9 |
25 files changed, 177 insertions, 18 deletions
diff --git a/tests/infrastructure/clean.awk b/tests/infrastructure/clean.awk deleted file mode 100644 index 1208b1ef..00000000 --- a/tests/infrastructure/clean.awk +++ /dev/null @@ -1,13 +0,0 @@ -{ - # Shell like comments - gsub(/^#.*$/, "", $0) - - # Strip leading and trailing white space - gsub(/^[[:blank:]]*/, "", $0) - gsub(/[[:blank:]]*$/, "", $0) - - # Only accept the line, if it contains something - if (NF) { - print $0 - } -} diff --git a/tests/README.md b/tests/old/README.md index f789c990..34dc9255 100644 --- a/tests/README.md +++ b/tests/old/README.md @@ -1,6 +1,18 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # How to write a test -Test are simple derivations, put into the `by-name` directory. As you +Test are simple derivations, put into the `by-name` directory. As you often want to test configuration, the 'standard' nixos-vm-test function starts a vm with the specified configuration and lets you run a python test script. @@ -78,7 +90,7 @@ Sleep for `ARGS` seconds. #### `Expect` -Grep the currently visible screen for the regex `ARGS`. This regex +Grep the currently visible screen for the regex `ARGS`. This regex must match. #### `ExpectNot` diff --git a/tests/by-name/le/less/data/test.file b/tests/old/by-name/le/less/data/test.file index 9e9f8931..9e9f8931 100644 --- a/tests/by-name/le/less/data/test.file +++ b/tests/old/by-name/le/less/data/test.file diff --git a/tests/old/by-name/le/less/data/test.file.license b/tests/old/by-name/le/less/data/test.file.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/le/less/data/test.file.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/le/less/test.desc b/tests/old/by-name/le/less/test.desc index a0c49e7b..a0c49e7b 100644 --- a/tests/by-name/le/less/test.desc +++ b/tests/old/by-name/le/less/test.desc diff --git a/tests/old/by-name/le/less/test.desc.license b/tests/old/by-name/le/less/test.desc.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/le/less/test.desc.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/le/less/test.nix b/tests/old/by-name/le/less/test.nix index cdd8209c..c9716ffc 100644 --- a/tests/by-name/le/less/test.nix +++ b/tests/old/by-name/le/less/test.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. {mkTest, ...}: mkTest { name = "less"; diff --git a/tests/by-name/nv/nvim-checkhealth/test.desc b/tests/old/by-name/nv/nvim-checkhealth/test.desc index 169cf49f..169cf49f 100644 --- a/tests/by-name/nv/nvim-checkhealth/test.desc +++ b/tests/old/by-name/nv/nvim-checkhealth/test.desc diff --git a/tests/old/by-name/nv/nvim-checkhealth/test.desc.license b/tests/old/by-name/nv/nvim-checkhealth/test.desc.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/nv/nvim-checkhealth/test.desc.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/nv/nvim-checkhealth/test.nix b/tests/old/by-name/nv/nvim-checkhealth/test.nix index 399a25ff..cb04e758 100644 --- a/tests/by-name/nv/nvim-checkhealth/test.nix +++ b/tests/old/by-name/nv/nvim-checkhealth/test.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. { mkTest, extraModules, diff --git a/tests/by-name/nv/nvim-neorg/data/index.norg b/tests/old/by-name/nv/nvim-neorg/data/index.norg index 4d643019..4d643019 100644 --- a/tests/by-name/nv/nvim-neorg/data/index.norg +++ b/tests/old/by-name/nv/nvim-neorg/data/index.norg diff --git a/tests/old/by-name/nv/nvim-neorg/data/index.norg.license b/tests/old/by-name/nv/nvim-neorg/data/index.norg.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/nv/nvim-neorg/data/index.norg.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/nv/nvim-neorg/data/reference.norg b/tests/old/by-name/nv/nvim-neorg/data/reference.norg index b572a469..b572a469 100644 --- a/tests/by-name/nv/nvim-neorg/data/reference.norg +++ b/tests/old/by-name/nv/nvim-neorg/data/reference.norg diff --git a/tests/old/by-name/nv/nvim-neorg/data/reference.norg.license b/tests/old/by-name/nv/nvim-neorg/data/reference.norg.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/nv/nvim-neorg/data/reference.norg.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/nv/nvim-neorg/test.desc b/tests/old/by-name/nv/nvim-neorg/test.desc index bd1e8f49..bd1e8f49 100644 --- a/tests/by-name/nv/nvim-neorg/test.desc +++ b/tests/old/by-name/nv/nvim-neorg/test.desc diff --git a/tests/old/by-name/nv/nvim-neorg/test.desc.license b/tests/old/by-name/nv/nvim-neorg/test.desc.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/nv/nvim-neorg/test.desc.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/nv/nvim-neorg/test.nix b/tests/old/by-name/nv/nvim-neorg/test.nix index ee0e1b52..82cb533d 100644 --- a/tests/by-name/nv/nvim-neorg/test.nix +++ b/tests/old/by-name/nv/nvim-neorg/test.nix @@ -1,6 +1,15 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. { mkTest, - extraModules, + extra_modules, pkgs, ... }: @@ -25,7 +34,7 @@ mkTest { }; home-manager.users.soispha = { imports = [ - extraModules.nixvim.homeManagerModule + extra_modules.home.nixvim ]; }; }; diff --git a/tests/by-name/ya/yambar/test.desc b/tests/old/by-name/ya/yambar/test.desc index 067c201e..067c201e 100644 --- a/tests/by-name/ya/yambar/test.desc +++ b/tests/old/by-name/ya/yambar/test.desc diff --git a/tests/old/by-name/ya/yambar/test.desc.license b/tests/old/by-name/ya/yambar/test.desc.license new file mode 100644 index 00000000..eae6a84c --- /dev/null +++ b/tests/old/by-name/ya/yambar/test.desc.license @@ -0,0 +1,9 @@ +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/tests/by-name/ya/yambar/test.nix b/tests/old/by-name/ya/yambar/test.nix index c0e94110..0e4d0033 100644 --- a/tests/by-name/ya/yambar/test.nix +++ b/tests/old/by-name/ya/yambar/test.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. {mkTest, ...}: mkTest { name = "yambar"; diff --git a/tests/default.nix b/tests/old/default.nix index af004feb..d13723b4 100644 --- a/tests/default.nix +++ b/tests/old/default.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. { lib, nixLib, diff --git a/tests/old/infrastructure/clean.awk b/tests/old/infrastructure/clean.awk new file mode 100644 index 00000000..0362d38b --- /dev/null +++ b/tests/old/infrastructure/clean.awk @@ -0,0 +1,23 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + +{ + # Shell like comments + gsub(/^#.*$/, "", $0) + + # Strip leading and trailing white space + gsub(/^[[:blank:]]*/, "", $0) + gsub(/[[:blank:]]*$/, "", $0) + + # Only accept the line, if it contains something + if (NF) { + print $0 + } +} diff --git a/tests/infrastructure/default.nix b/tests/old/infrastructure/default.nix index 9e6ab08c..4696a99f 100644 --- a/tests/infrastructure/default.nix +++ b/tests/old/infrastructure/default.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. { pkgs, myPkgs, @@ -38,7 +47,7 @@ nixos-lib.runTest { machine = {config, ...}: { imports = [ - extraModules.home-manager + extra_modules.home.home-manager ../../modules/by-name/us/users/module.nix ] ++ configuration.imports; diff --git a/tests/infrastructure/driver.sh b/tests/old/infrastructure/driver.sh index 4992b5bc..a8b241d2 100644 --- a/tests/infrastructure/driver.sh +++ b/tests/old/infrastructure/driver.sh @@ -1,4 +1,15 @@ #! /usr/bin/env bash + +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + set -e msg() { diff --git a/tests/infrastructure/run.nix b/tests/old/infrastructure/run.nix index 5bab3dc4..3148a2d9 100644 --- a/tests/infrastructure/run.nix +++ b/tests/old/infrastructure/run.nix @@ -1,3 +1,12 @@ +# nixos-config - My current NixOS configuration +# +# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +# SPDX-License-Identifier: GPL-3.0-or-later +# +# This file is part of my nixos-config. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. { pkgs, lib, |
