diff options
author | Silvan Mosberger <silvan.mosberger@tweag.io> | 2023-10-12 00:38:43 +0200 |
---|---|---|
committer | Silvan Mosberger <silvan.mosberger@tweag.io> | 2023-10-12 02:27:13 +0200 |
commit | f394f738faaee2a749eae7c507dccb1830dd440a (patch) | |
tree | 01286800e4c2a9126120b4e10e29ec7b53a8d7d3 /pkgs/test | |
parent | 26cec0dbe31c11fc8ccbf2fa32d503212a217916 (diff) | |
download | nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar.gz nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar.bz2 nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar.lz nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar.xz nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.tar.zst nixlib-f394f738faaee2a749eae7c507dccb1830dd440a.zip |
tests.nixpkgs-check-by-name: Improve an error message
Diffstat (limited to 'pkgs/test')
4 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/test/nixpkgs-check-by-name/src/eval.rs b/pkgs/test/nixpkgs-check-by-name/src/eval.rs index 458986a687a0..53a813045eee 100644 --- a/pkgs/test/nixpkgs-check-by-name/src/eval.rs +++ b/pkgs/test/nixpkgs-check-by-name/src/eval.rs @@ -119,7 +119,7 @@ pub fn check_values<W: io::Write>( if !valid { error_writer.write(&format!( - "pkgs.{package_name}: This attribute is not defined as `pkgs.callPackage {} {{ ... }}`.", + "pkgs.{package_name}: This attribute is manually defined (most likely in pkgs/top-level/all-packages.nix), which is only allowed if the definition is of the form `pkgs.callPackage {} {{ ... }}`.", relative_package_file.display() ))?; continue; diff --git a/pkgs/test/nixpkgs-check-by-name/tests/override-different-file/expected b/pkgs/test/nixpkgs-check-by-name/tests/override-different-file/expected index 1c6377d8aef0..36fa40d18ead 100644 --- a/pkgs/test/nixpkgs-check-by-name/tests/override-different-file/expected +++ b/pkgs/test/nixpkgs-check-by-name/tests/override-different-file/expected @@ -1 +1 @@ -pkgs.nonDerivation: This attribute is not defined as `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. +pkgs.nonDerivation: This attribute is manually defined (most likely in pkgs/top-level/all-packages.nix), which is only allowed if the definition is of the form `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. diff --git a/pkgs/test/nixpkgs-check-by-name/tests/override-no-call-package/expected b/pkgs/test/nixpkgs-check-by-name/tests/override-no-call-package/expected index 1c6377d8aef0..36fa40d18ead 100644 --- a/pkgs/test/nixpkgs-check-by-name/tests/override-no-call-package/expected +++ b/pkgs/test/nixpkgs-check-by-name/tests/override-no-call-package/expected @@ -1 +1 @@ -pkgs.nonDerivation: This attribute is not defined as `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. +pkgs.nonDerivation: This attribute is manually defined (most likely in pkgs/top-level/all-packages.nix), which is only allowed if the definition is of the form `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. diff --git a/pkgs/test/nixpkgs-check-by-name/tests/override-no-file/expected b/pkgs/test/nixpkgs-check-by-name/tests/override-no-file/expected index 1c6377d8aef0..36fa40d18ead 100644 --- a/pkgs/test/nixpkgs-check-by-name/tests/override-no-file/expected +++ b/pkgs/test/nixpkgs-check-by-name/tests/override-no-file/expected @@ -1 +1 @@ -pkgs.nonDerivation: This attribute is not defined as `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. +pkgs.nonDerivation: This attribute is manually defined (most likely in pkgs/top-level/all-packages.nix), which is only allowed if the definition is of the form `pkgs.callPackage pkgs/by-name/no/nonDerivation/package.nix { ... }`. |