From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Apropos 54f297904e0c: Temporarily comment out CC Mode from tests which are incompatible with it. Date: Thu, 17 Jan 2019 16:43:50 +0000 Message-ID: <20190117164350.GA18314@ACM> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1547744174 21215 195.159.176.226 (17 Jan 2019 16:56:14 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 17 Jan 2019 16:56:14 +0000 (UTC) User-Agent: Mutt/1.10.1 (2018-07-13) Cc: emacs-devel To: =?iso-8859-1?Q?Jo=E3o_T=E1vora?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jan 17 17:56:10 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gkAxb-0005IL-3e for ged-emacs-devel@m.gmane.org; Thu, 17 Jan 2019 17:56:07 +0100 Original-Received: from localhost ([127.0.0.1]:47924 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gkAzh-0008IB-S1 for ged-emacs-devel@m.gmane.org; Thu, 17 Jan 2019 11:58:17 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:60840) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gkAzZ-0008FR-On for emacs-devel@gnu.org; Thu, 17 Jan 2019 11:58:10 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gkAwU-0004Qp-8A for emacs-devel@gnu.org; Thu, 17 Jan 2019 11:55:00 -0500 Original-Received: from colin.muc.de ([193.149.48.1]:41006 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1gkAwQ-0004Gy-RF for emacs-devel@gnu.org; Thu, 17 Jan 2019 11:54:56 -0500 Original-Received: (qmail 19878 invoked by uid 3782); 17 Jan 2019 16:54:51 -0000 Original-Received: from acm.muc.de (p4FE15FC6.dip0.t-ipconnect.de [79.225.95.198]) by colin.muc.de (tmda-ofmipd) with ESMTP; Thu, 17 Jan 2019 17:54:50 +0100 Original-Received: (qmail 19005 invoked by uid 1000); 17 Jan 2019 16:43:50 -0000 Content-Disposition: inline In-Reply-To: X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x [fuzzy] X-Received-From: 193.149.48.1 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.devel:232432 Archived-At: Hello, Joćo. On Thu, Jan 17, 2019 at 14:57:04 +0000, Joćo Tįvora wrote: > Hi Alan, > Please revert this change ASAP: > commit 54f297904e0c641fcfd81f16e9a87177124a27be > Author: Alan Mackenzie > Date: Thu Jan 17 12:51:40 2019 +0000 > Temporarily comment out CC Mode from tests which are incompatible > with it. That would leave lots of failed tests in make check. People have already remarked on those failures, implicitly asking me to fix them. > I thought we had agreed that the way to "work around" other people's > unit tests, even if temporarily, is to work in a separate git branch. My understanding, from a previous encounter, was that having no failing unit tests was of a high priority. I've only commented a little bit out, I haven't made any permanent, unreverseable changes. > The other electric-pair-test that I disabled 6 months ago, that was one that > also temporary, is till there. But now you destroyed even the "expected > failure" mark. Why?? Is the test passing unexpectedly? With that test in, I got the error message: "No test named `electric-pair-whitespace-chomping-2-at-point-4-in-c++-mode-in-strings'", and no other tests were performed, leaving an electric-tests.log file 86 bytes long. That's why I commented it out. This may be some glitch in the testing system. > @@ -396,10 +397,10 @@ whitespace-chomping-2 > ;; mode will sort this out eventually, using some new e-p-m machinery. > ;; See > ;; https://lists.gnu.org/archive/html/emacs-devel/2018-06/msg00535.html > -(setf > - (ert-test-expected-result-type > - (ert-get-test > 'electric-pair-whitespace-chomping-2-at-point-4-in-c++-mode-in-strings)) > - :failed) > +;; (setf > +;; (ert-test-expected-result-type > +;; (ert-get-test > 'electric-pair-whitespace-chomping-2-at-point-4-in-c++-mode-in-strings)) > +;; :failed) > But this is much more intrusive. In particular > ;; Tests commented out, since C Mode does not use > ;; electric-layout-mode. 2019-01-17, ACM > C Mode doesn't use electric-layout mode, but a user can surely > decide he wants to use it in c-mode, can he not?? No. Certainly not at the moment. > These tests pass fine currently. When I ran them, there were lots of failures, because the tests assumed electric-layout-mode was active. > Please revert this fix and lets discuss why you need to disable tests. It's not a fix, it's a temporary workaround. Anyhow, surely the implementation of Emacs should not be constrained by its tests? Rather the tests should test the chosen implementation. > If we come to the conclusion that some tests are asserting unreasonable > expectations about the functionality you develop, we can disable them on a > case by case basis! I would have done that, indeed tried to do that, but the lack of documentation of electric-pair-test-for, electric-pair-define-test-form and so on, many of them with 8, 9 or more parameters, made that too difficult, given the urgency I felt to produce a workaround. > If on the other hand, if you need to do some work "temporarily", then > the best way to do it without disturbing other people's developments > is to do it in a separate branch. I fixed bug #33794[*] on master, as I always do with CC Mode bugs (and most other sorts of bugs, too). That fix is, in principle, sound. I didn't discover the problems with the unit tests till later (though I admit I should have done). [*] That is, Beatrix Klebe's bug about CC Mode's auto-newlines not working with electric-pair-mode. Anyhow, apologies, and all that, but I don't want to spend any more time on this topic today or until tomorrow evening, since I've got an exam coming up tomorrow. But I promise I'll get back to you (including answering your other post) either late tomorrow or on Saturday. > Joćo -- Alan Mackenzie (Nuremberg, Germany).