From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Merten Newsgroups: gmane.emacs.devel Subject: Re: testcover: setf-method and treatment of `defcustom' Date: Wed, 12 Sep 2012 21:32:47 +0200 Message-ID: <6642.1347478367@theowa.merten-home.homelinux.org> References: <6900.1347261102@theowa.merten-home.homelinux.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1347478393 30566 80.91.229.3 (12 Sep 2012 19:33:13 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 12 Sep 2012 19:33:13 +0000 (UTC) Cc: Jonathan Yavner To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Sep 12 21:33:16 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TBsgW-00069x-6v for ged-emacs-devel@m.gmane.org; Wed, 12 Sep 2012 21:33:16 +0200 Original-Received: from localhost ([::1]:53390 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsgS-00089i-Hm for ged-emacs-devel@m.gmane.org; Wed, 12 Sep 2012 15:33:12 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:40220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsgP-00089S-Lm for emacs-devel@gnu.org; Wed, 12 Sep 2012 15:33:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TBsgO-0001SW-Ld for emacs-devel@gnu.org; Wed, 12 Sep 2012 15:33:09 -0400 Original-Received: from moutng.kundenserver.de ([212.227.17.9]:53146) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TBsgO-0001S4-Bz for emacs-devel@gnu.org; Wed, 12 Sep 2012 15:33:08 -0400 Original-Received: from theowa.merten-home.homelinux.org (ip-109-41-78-61.web.vodafone.de [109.41.78.61]) by mrelayeu.kundenserver.de (node=mrbap0) with ESMTP (Nemesis) id 0MgYIJ-1Srky01iqN-00O0gw; Wed, 12 Sep 2012 21:33:06 +0200 Original-Received: by theowa.merten-home.homelinux.org (Postfix, from userid 1000) id 260F1400C7; Wed, 12 Sep 2012 21:32:47 +0200 (CEST) Original-Received: from theowa.merten-home.homelinux.org (localhost [127.0.0.1]) by theowa.merten-home.homelinux.org (Postfix) with ESMTP id 20BE97A00C; Wed, 12 Sep 2012 21:32:47 +0200 (CEST) In-reply-to: <6900.1347261102@theowa.merten-home.homelinux.org> Comments: In-reply-to Stefan Merten message dated "Mon, 10 Sep 2012 09:11:42 +0200." X-Mailer: MH-E 8.2; nmh 1.3; GNU Emacs 23.1.1 X-Provags-ID: V02:K0:a0JcjjDHGIcKBGCkEZcvMiIWwwuIgSvEq8fG4TQVkaz 0waEw6c9fWOOQyTtAiX/uaM6k39ZxBfQL5g0sqDQ4UhA8LAfF+ bykObTCtAZLmeBUqjx6T/20dQygqQlp/fGkNw8+rENnLncT6VF UP1cz/zIMmmT2hzxpCbZlLmdlro4fMYRrWUML8XstIjRh8iawB r3tcpd6Pl5NOLm6w0dF7ivTQ/pwjF+bIXa6s+k21hd2juESg/u xgIIWieTBLUy6TQF+EU39FUB9wqEnO1pGIpLHrn3wDie3zxZL6 FG9OZn23R63Bmx42CsorkEMCj9chH4YKReadrhilhsH9bJwqVQ 1/60xyI66pOvzbkvDWQP+sHxLxR4giH4bToiOtUsi7Q8bcPRrx q8F1ZBh4XMssmeqxwSM3UQZaQytLGQ2OTw= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 212.227.17.9 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:153257 Archived-At: --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Hi! 2 days ago Stefan Merten wrote: > I still had another error left, however. >=20 > Value of form marked with `1value' does vary: ... >=20 > It took me some time to discover that for some reason `testcover' > treats `defcustom' like `defconst'. This is of course lethal for a > test which changes a customizable variable temporarily - e.g. by `let' > - to test a certain functionality. I now used `testcover' intensively and can see why there is a wish to treat a `defcustom' like a `defconst'. If you treat a `defcustom' like a normal `defvar' you get a brown splotch (i.e. the form had only a single value) for all the `defcustom' variables. This is annoying. OTOH in automated tests you *want* to override a `defcustom' to test behavior with a different customization. So treating `defcustom' as `defconst' unconditionally is certainly not an option. The natural thing which comes to mind is to create a configuration option here. For instance there could be another customizable `testcover' variable which lists all the `defcustom' variables you *do* want to treat as a variable. How does this sound? Gr=FC=DFe Stefan --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQCVAwUBUFDjXAnTZgC3zSk5AQKlgAP/VSvjYRmmkGTzT7gFXTM3jr4YvPE+yxNY Dvwtv1e/43quHcILT3Nrps+VymJwmzrN9l0AIkMrZ/oMx7A1eN4pT9m89tLqRf7t pdzIdGjdezCpmEFiac/rANrhX6yAmgNLoQpdxpsxObeOcgpkAexUJ28PU6vPP2jz oT+wmSHM3qE= =NF3U -----END PGP SIGNATURE----- --=-=-=--