From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Vladimir Kazanov Newsgroups: gmane.emacs.devel Subject: Re: [ELPA] New package: ert-font-lock Date: Sun, 19 Nov 2023 10:02:09 +0000 Message-ID: References: <87v89zz4v4.fsf@posteo.net> <87v89zjmcx.fsf@yahoo.com> <83fs13mduq.fsf@gnu.org> <87wmufunoz.fsf@thelio.lan> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30590"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , Po Lu , philipk@posteo.net, emacs-devel@gnu.org To: jm@pub.pink Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Nov 19 11:03:17 2023 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 1r4ee4-0007nU-PE for ged-emacs-devel@m.gmane-mx.org; Sun, 19 Nov 2023 11:03:16 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r4edF-0007Pu-EM; Sun, 19 Nov 2023 05:02:25 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r4edE-0007PL-5u for emacs-devel@gnu.org; Sun, 19 Nov 2023 05:02:24 -0500 Original-Received: from mail-lj1-x234.google.com ([2a00:1450:4864:20::234]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r4edC-0006iv-HT; Sun, 19 Nov 2023 05:02:23 -0500 Original-Received: by mail-lj1-x234.google.com with SMTP id 38308e7fff4ca-2c87adce180so6712031fa.0; Sun, 19 Nov 2023 02:02:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700388140; x=1700992940; darn=gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=u19nSY3fKJAuJ452n5O/i2wOCv8swQjZSnBT6mAlVp4=; b=mc2o9nZ45wotM9MYSgnQvaUc+KXaj1N4M2FMD6VwmxCK0NWJ9BLBgn6iTge0ZwEi6T oKHbLXkDD78wFGJj7SQqvnY+R5ZNM/T9IwKXjN1hPs3qzW+3DB67611JVTA6U03iW7Sn SDRZIxsP6qm/KPa9PaNbn0R+rFGgmYJupJLcNF6UujtLbtywTTwBHkXpXvOY2p42ysoW Yg1wor2Ew+zDXF1B+Pcnn9N5WDA2qsXweczqrNps1TRaWfVCeLySt3OtS4HfhVBOVyZD 6T/EB1zbnwZzu1rluaEJss4jV8IZq6rjjf5B+W24IMDUMIs5u4T5+EoQngolNkwtN9zr RWaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700388140; x=1700992940; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=u19nSY3fKJAuJ452n5O/i2wOCv8swQjZSnBT6mAlVp4=; b=hjjQ3CBa0ne1UOjyupiCt83Cvha8esBf2sdnBjMLIlrh3P1q6AT7/orqZdIBNj4/jf qmUZm+TQ7GYgw8xpeL5padj9aCfSNdjRZGIPNhHQ0ypuAr+lzEr1RvK64U4WXiYbgwRk Q4lAUDkwPnB60gzKb3I932MJKcvLriJDx8K6Sfl6crV/+b0l/yApWOojbxvP8/Nb6YKb ScLANUFPoLvb2E0HAJtUTgg83n8ncla3WSKvhGdbmmWIe+hfKkBK4wspkxUpxeA4IGAY aaTidDkrSvAA6zoN7KDpBIOTK/Hc4AUuyVNw3g1mrA4rijdPq0x378PcnOi6nOO/0AbO vF2g== X-Gm-Message-State: AOJu0YyXKkQv4HxnEUZyuJ8rdN1V9nnweHXLF8AdKOM3tng8z7annEf6 cqpoGMjq3UOrZmNtWMQVPwHeKFzYIu1B3tUdYeI8l0LKRQ== X-Google-Smtp-Source: AGHT+IE8u0KB0DLvlRd06EQmRZJTjY9PgwWaQFMEtW6ki0wl8hvUdYOQOsEw+Wrvmt1s2V8Gx4ZjfIN+jGBrHbP+IB4= X-Received: by 2002:a2e:b60c:0:b0:2ba:6519:c50f with SMTP id r12-20020a2eb60c000000b002ba6519c50fmr3177841ljn.52.1700388140269; Sun, 19 Nov 2023 02:02:20 -0800 (PST) In-Reply-To: <87wmufunoz.fsf@thelio.lan> Received-SPF: pass client-ip=2a00:1450:4864:20::234; envelope-from=vekazanov@gmail.com; helo=mail-lj1-x234.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:312961 Archived-At: > faceup.el is already included and seems to provide similar > functionality. Vladimir could you provide a comparison between > your package and faceup? Sure! I use Anders' set of tools intensively but faceup.el is not exactly what I was looking for. Let me explain. faceup.el dumps the current state of highlighting into a separate file and makes it possible to report any differences. This makes it possible to "freeze" some state and then make sure nothing happens in the bigger picture. It provides a relatively developed markup language that surfaces most of the highlighting features of Emacs. The library is about 700 LOC excluding the header. So to me faceup.el is a way to save and check full snapshots of syntax highlighting. This is an *extremely* useful tool for tweaking an already existing complicated highlighting system. ert-font-lock.el is the simpler of the two (maybe 200 LOC). It introduces a way to non-intrusively say something: "check that the face above is right", and that's about it. The other benefit is that it's modelled on Tree-sitter unit tests which makes porting already existing TS grammar highlighting unit tests trivial. So instead of snapshot-oriented testing this becomes closer to the original idea of unit tests: adding small tests incrementally. -- Regards, Vladimir Kazanov