summary refs log tree commit diff
path: root/lib/tests/modules.sh
diff options
context:
space:
mode:
authorSilvan Mosberger <contact@infinisil.com>2020-03-16 21:10:05 +0100
committerSilvan Mosberger <contact@infinisil.com>2020-03-18 04:38:53 +0100
commite931de58a2f724c3632b7c8a656fb47489ecc963 (patch)
tree1b56b24a3d4b0655e2ef3de6964e8e6203ea346f /lib/tests/modules.sh
parent15c873b486347e7861c64fb0b5a7852be9fc82e4 (diff)
downloadnixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar.gz
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar.bz2
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar.lz
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar.xz
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.tar.zst
nixpkgs-e931de58a2f724c3632b7c8a656fb47489ecc963.zip
lib/modules: Fix type checks not being done before merging
Co-Authored-By: Robert Hensing <robert@roberthensing.nl>
Diffstat (limited to 'lib/tests/modules.sh')
-rwxr-xr-xlib/tests/modules.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/tests/modules.sh b/lib/tests/modules.sh
index 0e2fd0bf65d..7713207dadd 100755
--- a/lib/tests/modules.sh
+++ b/lib/tests/modules.sh
@@ -198,6 +198,10 @@ checkConfigOutput "empty" config.value.foo ./declare-lazyAttrsOf.nix ./attrsOf-c
 checkConfigError 'The option path .* is an attribute set of options, but it is defined to not be an attribute set in' \
   config.value ./declare-option-set.nix ./define-value-int-zero.nix
 
+# Even with multiple assignments, a type error should be thrown if any of them aren't valid
+checkConfigError 'The option value .* in .* is not of type .*' \
+  config.value ./declare-int-unsigned-value.nix ./define-value-list.nix ./define-value-int-positive.nix
+
 cat <<EOF
 ====== module tests ======
 $pass Pass