Gentoo Archives: gentoo-portage-dev

From: Alexander Berntsen <alexander@××××××.net>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] When must we write tests, when is it optional?
Date: Sat, 18 Jan 2014 01:53:54
Message-Id: 52D9DEC0.5080705@plaimi.net
In Reply to: [gentoo-portage-dev] When must we write tests, when is it optional? by Tom Wijsman
1 -----BEGIN PGP SIGNED MESSAGE-----
2 Hash: SHA256
3
4 On 18/01/14 01:10, Tom Wijsman wrote:
5 > Should writing tests be a requirement? When?
6 Thank you for raising the issue. We need a clear policy on this. (And
7 this policy should be obviously documented.) And in my opinion, tests
8 are worthless unless we do some variant of TDD[0].
9
10 We should write tests before we write implementations. This makes you
11 think more deeply about your design, and it forces you to actually
12 *write* the tests. I have seen time and time again projects where
13 tests are supposed to be written post-implementation. Usually, tests
14 are written for the first month (that's an optimistic estimate), and
15 then the implementation is so far ahead that tests are simply dropped
16 altogether.
17
18
19 [0] <https://en.wikipedia.org/wiki/Test-driven_development>, for
20 those of you who are unfamiliar with TDD.
21
22 - --
23 Alexander
24 alexander@××××××.net
25 http://plaimi.net/~alexander
26 -----BEGIN PGP SIGNATURE-----
27 Version: GnuPG v2.0.22 (GNU/Linux)
28 Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
29
30 iF4EAREIAAYFAlLZ3sAACgkQRtClrXBQc7WUUAEAni2RZNcbR8wyYKSJWAPXlgaR
31 /CB3JDkzK3ZcOTn5sKcBAJ3tZ3jV+LLBg/Ls1f651gd6jECAfBvWiYAMFa8aUvSa
32 =x2nL
33 -----END PGP SIGNATURE-----