From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: FEATURE REQUEST: Make etags recognize 'ert-deftest' by default in .el files Date: Sun, 24 Jul 2022 08:46:05 +0300 Message-ID: <83fsirgj1e.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6377"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: rswgnu@gmail.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Jul 24 07:47:50 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oFUSy-0001US-SQ for ged-emacs-devel@m.gmane-mx.org; Sun, 24 Jul 2022 07:47:49 +0200 Original-Received: from localhost ([::1]:44952 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oFUSx-0001ad-AP for ged-emacs-devel@m.gmane-mx.org; Sun, 24 Jul 2022 01:47:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44230) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oFURN-0000tG-1m for emacs-devel@gnu.org; Sun, 24 Jul 2022 01:46:09 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:53026) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oFURM-0004Ae-NW; Sun, 24 Jul 2022 01:46:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=j3dZuqiqZ2sSDKR0NyUw9WfTL6PXgKSHl1/mdNkxo0I=; b=B59/FQX1cKcT BqoHhM91demmDD0+bFFvMJ/X6g+EklcX1UxXT6Br3k3zSQlHWStvuRrVeZp3oBKotwZlDOEpjJRBI A42ZC9LOzptvR1gv88nbUtkct+8ANkkPIgMy+wq9H9ztxCYxCNtYROPhx0sW5hC+qVVsd+KZcaaf1 Agbl0QoLJXEvLoTQ9j9cWgj1RDgj/Su//NhEjW1wmyqUIKIxLz3EzQGcnuenL+kldbwRc1+co6ghD K44HgQa+G5Ot/iSfXKitQ1uBnqlH4EF4dfcN4Zx7tIopVonxpibCRHOexPt/BobrjrVN34RqM9WET XjjAvmd92A6fom7nJvZJ/Q==; Original-Received: from [87.69.77.57] (port=2479 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oFURJ-00030J-P5; Sun, 24 Jul 2022 01:46:08 -0400 In-Reply-To: (message from Robert Weiner on Sat, 23 Jul 2022 18:25:16 -0400) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:292567 Archived-At: > From: Robert Weiner > Date: Sat, 23 Jul 2022 18:25:16 -0400 > > ert.el is a standard testing framework in Emacs which uses 'ert-deftest' to define test functions. Because it > does not begin with 'def', it is not recognized as a definition by etags and libraries or packages with many > tests will not have these show up for navigation when using default calls to etags. > > I would suggest one of two solutions: > > 1. Modify etags to automatically recognize such definitions by default. (I tried using the --regex option but > had little luck with that due to it not liking an opening paren without a closing one in the regex). > > 2. Add an alias of 'def-ert-test' and suggest people use that instead so that it is picked up by etags. #1 is > obviously better given the number of existing test definitions that exist already. Please show what you tried with --regex, I think this is the easiest solution (we already do something similar to recognize DEFVAR_* in C sources, see src/Makefile.in). Thanks. P.S. Feature requests are best submitted as bug reports, so that our issue tracker records the discussion and gives it an ID for future references. Would you please convert this to such a bug report?