Unverified Commit ad175bca authored by Maximilian Bosch's avatar Maximilian Bosch
Browse files

nixos/nextcloud: fix eval of tests

Currently failing with

    error: cannot coerce a set to a string: { __functionArgs = «thunk»; __functor = «thunk»; }

This comes from the `extraTests` option I added to the test modules to
compose certain tests a little nicer. It's of type

    either (functionTo ...) str

and it seems like the `functionTo` part now returns a functor (i.e. an
attr-set that can be invoked as function). This is caught by
`lib.isFunction`, but `builtins.isFunction` returns `false`.

Hence, switching to the former fixes this.
parent dc9b690d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -80,7 +80,7 @@ let
              "${test-helpers.rclone} ${test-helpers.check-sample}"
          )

      ${if builtins.isFunction test-helpers.extraTests then test-helpers.extraTests args else test-helpers.extraTests}
      ${if pkgs.lib.isFunction test-helpers.extraTests then test-helpers.extraTests args else test-helpers.extraTests}
    '';
  };