From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Barry OReilly Newsgroups: gmane.emacs.devel Subject: Re: Simple lisp-tests.el and commit privs Date: Wed, 21 Aug 2013 19:06:42 -0400 Message-ID: References: <87y584c6gv.fsf@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11c303f2114ce704e47d3ad1 X-Trace: ger.gmane.org 1377126409 21266 80.91.229.3 (21 Aug 2013 23:06:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 21 Aug 2013 23:06:49 +0000 (UTC) Cc: Dmitry Gutov , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Aug 22 01:06:52 2013 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 1VCHUI-0007L6-Sy for ged-emacs-devel@m.gmane.org; Thu, 22 Aug 2013 01:06:51 +0200 Original-Received: from localhost ([::1]:57040 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VCHUI-0003Ve-CJ for ged-emacs-devel@m.gmane.org; Wed, 21 Aug 2013 19:06:50 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45950) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VCHUD-0003VU-Am for emacs-devel@gnu.org; Wed, 21 Aug 2013 19:06:47 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VCHUC-0000Ro-8t for emacs-devel@gnu.org; Wed, 21 Aug 2013 19:06:45 -0400 Original-Received: from mail-ob0-x22b.google.com ([2607:f8b0:4003:c01::22b]:45903) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VCHUC-0000Rc-3D for emacs-devel@gnu.org; Wed, 21 Aug 2013 19:06:44 -0400 Original-Received: by mail-ob0-f171.google.com with SMTP id tb18so2175365obb.30 for ; Wed, 21 Aug 2013 16:06:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=y7g2dZrohVdLQpICOnersewCOwYO/8IS9IL1WlwrQ4U=; b=P4W3zZObM4cQa3lFW2nEmLaGyJOQOdy7vwD4dpSLdoWgszAwGaeaINuADlmKnUry1t 1B2945kiLnzy7otS2TnT3naDlFVjonzzmdp8zjB2yfYKuM86So5xyN2u6Ka58zVocYJ3 AZLzqSl8H9fSr1Bxt91iNxui6Ukwpc0A5xPDsbRIvZb3UWGLFUGQVk0E4+czTnzcHN+E ZaESWjtIzrQV2P8SfYwXmFepqHCO1j3abUPsG7vBU5nY6Uk05ENpKlNjJbQKeWHa4qlj T2c+8o2AT+amEpYH3VdiZWxVXJW3sTPgZfYma4pPWQTNg4s4rNHOJfEmBGitweAZGJvp rlVw== X-Received: by 10.60.47.129 with SMTP id d1mr5045384oen.84.1377126403090; Wed, 21 Aug 2013 16:06:43 -0700 (PDT) Original-Received: by 10.76.89.194 with HTTP; Wed, 21 Aug 2013 16:06:42 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4003:c01::22b 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:162960 Archived-At: --001a11c303f2114ce704e47d3ad1 Content-Type: text/plain; charset=ISO-8859-1 > You may have to run the test by first flushing all the code to the > left margin before reindenting That would certainly make the tests better. Only testing preindented buffers is good but insufficient. What you describe is a good way to test non preindented buffers. > Oh, you're referring to known indentation problems, where you want to > have the test but have it be marked as "expected". > > Yes, that's currently not really supported: I try to put "FIXME" on > the corresponding lines, but very often an incorrect indentation on > one line impact subsequent lines as well, so not only does the > "diff" not care about those FIXME markers, but you can get false > positives or false negatives to boot. Sounds more complex than using ERT :expected-result. If I indicate :expected-result is :failed on an invocation of a test/indent test from ERT, it would suppress all the expected successes because of one expected failure. Alternatively, the test could filter out lines with "FIXME", but that's ugly. I think finer grained ERT tests that can be marked as :expected-result of :passed or :failed (and don't need to parse for FIXMEs) are the better approach for test/automated 'make check' tests. --001a11c303f2114ce704e47d3ad1 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
> You may have to run the test by first flushing all th= e code to the
> left margin before reindenting

That would cert= ainly make the tests better. Only testing preindented
buffers is good bu= t insufficient. What you describe is a good way to
test non preindented buffers.

> Oh, you're referring to known= indentation problems, where you want to
> have the test but have it = be marked as "expected".
>
> Yes, that's currentl= y not really supported: I try to put "FIXME" on
> the corresponding lines, but very often an incorrect indentation on> one line impact subsequent lines as well, so not only does the
>= ; "diff" not care about those FIXME markers, but you can get fals= e
> positives or false negatives to boot.

Sounds more complex than = using ERT :expected-result.

If I indicate :expected-result is :faile= d on an invocation of a
test/indent test from ERT, it would suppress all= the expected
successes because of one expected failure. Alternatively, the test
could= filter out lines with "FIXME", but that's ugly.

I thi= nk finer grained ERT tests that can be marked as :expected-result
of :pa= ssed or :failed (and don't need to parse for FIXMEs) are the
better approach for test/automated 'make check' tests.

--001a11c303f2114ce704e47d3ad1--