summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorMartin Weinelt <hexa@darmstadt.ccc.de>2021-03-06 02:47:39 +0100
committerMartin Weinelt <hexa@darmstadt.ccc.de>2021-03-06 03:02:06 +0100
commit1050f1487b34270dd9e8f362f54a15f1f5e01d9f (patch)
tree2e3c37b49f68d51a24585555944941a1a6e649b3 /nixos
parent63a7edfc2489f9c859ab4b08a074289d2ff23ec3 (diff)
downloadnixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar.gz
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar.bz2
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar.lz
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar.xz
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.tar.zst
nixpkgs-1050f1487b34270dd9e8f362f54a15f1f5e01d9f.zip
nixos/home-assistant: disable tests on the package by default
We are running over 6000 tests by now and they take around 5 minutes
on faster machines and tests alot of components that endusers will not
actually be using. It is sufficient if we run them on package upgrades
and in the passthrough test.
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/services/misc/home-assistant.nix12
-rw-r--r--nixos/tests/home-assistant.nix2
2 files changed, 11 insertions, 3 deletions
diff --git a/nixos/modules/services/misc/home-assistant.nix b/nixos/modules/services/misc/home-assistant.nix
index 1f2e13f3732..f53c49a1ee6 100644
--- a/nixos/modules/services/misc/home-assistant.nix
+++ b/nixos/modules/services/misc/home-assistant.nix
@@ -183,8 +183,14 @@ in {
     };
 
     package = mkOption {
-      default = pkgs.home-assistant;
-      defaultText = "pkgs.home-assistant";
+      default = pkgs.home-assistant.overrideAttrs (oldAttrs: {
+        doInstallCheck = false;
+      });
+      defaultText = literalExample ''
+        pkgs.home-assistant.overrideAttrs (oldAttrs: {
+          doInstallCheck = false;
+        })
+      '';
       type = types.package;
       example = literalExample ''
         pkgs.home-assistant.override {
@@ -192,7 +198,7 @@ in {
         }
       '';
       description = ''
-        Home Assistant package to use.
+        Home Assistant package to use. By default the tests are disabled, as they take a considerable amout of time to complete.
         Override <literal>extraPackages</literal> or <literal>extraComponents</literal> in order to add additional dependencies.
         If you specify <option>config</option> and do not set <option>autoExtraComponents</option>
         to <literal>false</literal>, overriding <literal>extraComponents</literal> will have no effect.
diff --git a/nixos/tests/home-assistant.nix b/nixos/tests/home-assistant.nix
index 131f50747fe..726c7eb6acb 100644
--- a/nixos/tests/home-assistant.nix
+++ b/nixos/tests/home-assistant.nix
@@ -24,6 +24,8 @@ in {
     services.home-assistant = {
       inherit configDir;
       enable = true;
+      # includes the package with all tests enabled
+      package = pkgs.home-assistant;
       config = {
         homeassistant = {
           name = "Home";