nixpkgs/pkgs/stdenv
Léo Gaspard 02e1f00ffd
dovecot, opensmtpd: add link to test in meta.tests
Rationale
---------

Currently, tests are hard to discover. For instance, someone updating
`dovecot` might not notice that the interaction of `dovecot` with
`opensmtpd` is handled in the `opensmtpd.nix` test.

And even for someone updating `opensmtpd`, it requires manual work to go
check in `nixos/tests` whether there is actually a test, especially
given not so many packages in `nixpkgs` have tests and this is thus most
of the time useless.

Finally, for the reviewer, it is much easier to check that the “Tested
via one or more NixOS test(s)” has been checked if the file modified
already includes the list of relevant tests.

Implementation
--------------

Currently, this commit only adds the metadata in the package. Each
element of the `meta.tests` attribute is a derivation that, when it
builds successfully, means the test has passed (ie. following the same
convention as NixOS tests).

Future Work
-----------

In the future, the tools could be made aware of this `meta.tests`
attribute, and for instance a `--with-tests` could be added to
`nix-build` so that it also builds all the tests. Or a `--without-tests`
to build without all the tests. @Profpatsch described in his NixCon talk
such systems.

Another thing that would help in the future would be the possibility to
reasonably easily have cross-derivation nix tests without the whole
NixOS VM stack. @7c6f434c already proposed such a system.

This RFC currently handles none of these concerns. Only the addition of
`meta.tests` as metadata to be used by maintainers to remember to run
relevant tests.
2018-10-30 21:31:39 +09:00
..
cross stdenv linux, stdenv cross: Harmonize extraNativeBuildInputs 2018-09-18 16:27:04 -04:00
custom top-level: {build,host,target}Platform are defined in the stdenv instead 2017-07-07 12:55:02 -04:00
cygwin Fix invalid Baseaddress must be > 0x200000000 on cygwin 2018-04-14 14:06:09 +02:00
darwin Merge pull request #47233 from oxij/tree/mass-rebuild-noop-cleanups 2018-09-25 00:04:52 -04:00
freebsd fetchurl: cleanup, better errors 2018-02-18 14:24:53 +00:00
generic dovecot, opensmtpd: add link to test in meta.tests 2018-10-30 21:31:39 +09:00
linux Merge pull request #47245 from dtzWill/fix/coreutils-8.30-bootstrap 2018-09-25 12:10:27 +02:00
native [bot] treewide: remove unused 'inherit' in let blocks 2018-07-20 19:38:19 +00:00
nix cc-wrapper: Use stdenvNoCC to build 2017-09-26 14:08:21 -04:00
adapters.nix Merge pull request #37600 from abbradar/impureusenative 2018-10-13 14:09:55 +00:00
booter.nix treewide: Depend on targetPackages.stdenv.cc.bintools instead of binutils directly 2017-11-05 17:10:53 -05:00
common-path.nix bzip2: split into multiple outputs, refactor 2015-04-18 19:32:52 +02:00
default.nix [RFC] ppc64le enablement (#45340) 2018-08-21 15:31:34 -04:00