3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs
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
..
applications electrum: fix sha256 for 3.2.3 2018-10-28 16:27:13 +10:00
build-support Carnix: 0.7.2 -> 0.8.10 (#40587) 2018-10-28 00:06:29 +01:00
common-updater
data
desktops libgxps: fix CVE-2018-10733 2018-10-26 12:17:58 +02:00
development Merge pull request #47953 from lopsided98/openssl-arm 2018-10-28 14:08:02 +01:00
games
misc Fix higan typo 2018-10-27 11:45:59 +02:00
os-specific goku: init 0.1.11 2018-10-27 16:15:36 +01:00
servers dovecot, opensmtpd: add link to test in meta.tests 2018-10-30 21:31:39 +09:00
shells
stdenv dovecot, opensmtpd: add link to test in meta.tests 2018-10-30 21:31:39 +09:00
test
tools nixUnstable: 2.1pre6377_954d1f4d -> 2.2pre6520_18b4c53f 2018-10-28 00:01:27 -04:00
top-level dovecot, opensmtpd: add link to test in meta.tests 2018-10-30 21:31:39 +09:00