From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 10 17:04:54 2020 Received: (at submit) by debbugs.gnu.org; 10 Nov 2020 22:04:54 +0000 Received: from localhost ([127.0.0.1]:39245 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcbku-0001GR-WC for submit@debbugs.gnu.org; Tue, 10 Nov 2020 17:04:54 -0500 Received: from lists.gnu.org ([209.51.188.17]:56512) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcbkt-0001GK-No for submit@debbugs.gnu.org; Tue, 10 Nov 2020 17:04:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35924) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kcbkq-00048e-WC for bug-gnu-emacs@gnu.org; Tue, 10 Nov 2020 17:04:46 -0500 Received: from mout01.posteo.de ([185.67.36.65]:58715) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kcbkn-0003dl-3N for bug-gnu-emacs@gnu.org; Tue, 10 Nov 2020 17:04:44 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 00BF5160060 for ; Tue, 10 Nov 2020 23:04:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1605045876; bh=Qg6hMZIOhSvQp6AeO0y+9OCQ3LfNEgZvoXo/HFjR0Gg=; h=From:To:Subject:Date:From; b=oY6JZ7e+AFcDf59S8o+8ND4kF9JrkbYNjTQGMbtIo8LVS3uWgfvE40F+FjvQA0fRM lH8sZupzJqcSsoFtWdIqIVhVpMt64NpH3sCcIchFopwH6FUr/hrm4SwiVXpOzvYoNQ ME1JSgYLBlldzRZYOAECpJXDzjez40yQFnvddopqJr2FzqMEko/H+X80SZC0YOszaZ SZPp1DGj2H6GH7Ic4m14svOY06bKIzbia/PSL8+amEyg1bi5lP3XS2gIvcjI8/4eIJ 3VWj2dv/VGC3lRD1damNKGHRSvLOCB2Xm3/E2AxJtZ/shG8zbR24gTzm1vlqVq4kgA 5o4XmzvrqBixA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4CW22q1ybXz9rxQ for ; Tue, 10 Nov 2020 23:04:35 +0100 (CET) From: haj@posteo.de (Harald =?utf-8?Q?J=C3=B6rg?=) To: bug-gnu-emacs@gnu.org Subject: [PATCH] 28.0; cperl-mode: Test file makeover User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Date: Tue, 10 Nov 2020 23:04:34 +0100 Message-ID: <87mtzo27il.fsf@hajtower> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=185.67.36.65; envelope-from=haj@posteo.de; helo=mout01.posteo.de X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/10 15:23:33 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --=-=-= Content-Type: text/plain As the number of tests for (c)perl mode increases, the test file turns out to be somewhat untidy. The patch establishes a consistent naming scheme, factors out a piece of code which is used in several tests, and reorders the tests. The patch also eliminates a warning caused by using (next-line) instead of (forward-line 1), and allows the tests to run under Emacs 26. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-Cleanup-of-the-test-file-for-cperl-mode.patch Content-Description: Cleanup of tests for CPerl mode >From 43b3ddccba944e4f3d2b22091338f1bf304c207d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Harald=20J=C3=B6rg?= Date: Tue, 10 Nov 2020 23:01:00 +0100 Subject: [PATCH] ; Cleanup of the test file for cperl-mode. Eliminate a warning, enable tests to run under Emacs 26. Bug tests are consistently named and reordered. Repeated code is factored out. * test/lisp/progmodes/cperl-mode-tests.el (cperl--run-test-cases): New macro, factored out from various indentation / rewriting tests. Contains documentation of the format used by the cperl-mode-resources files. (cperl-test-bug-19709): Replace 'next-line' by 'forward-line'. (cperl-test-indent-exp), (cperl-test-indent-styles), (cperl-test-bug-30393): Use the new macro. (cperl-test-bug-19709): Make fit for Emacs 26. (cperl-test-indent-styles): Skip for Perl mode. --- test/lisp/progmodes/cperl-mode-tests.el | 334 +++++++++++------------- 1 file changed, 152 insertions(+), 182 deletions(-) diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index bd8a1a9f16..a0dd391840 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -34,6 +34,8 @@ cperl-test-mode (require 'ert) (require 'ert-x) +;;; Utilities + (defun cperl-test-ppss (text regexp) "Return the `syntax-ppss' of the first character matched by REGEXP in TEXT." (interactive) @@ -44,48 +46,98 @@ cperl-test-ppss (re-search-forward regexp) (syntax-ppss))) -(ert-deftest cperl-mode-test-bug-42168 () - "Verify that '/' is a division after ++ or --, not a regexp. -Reported in https://github.com/jrockway/cperl-mode/issues/45. -If seen as regular expression, then the slash is displayed using -font-lock-constant-face. If seen as a division, then it doesn't -have a face property." - :tags '(:fontification) - ;; The next two Perl expressions have divisions. Perl "punctuation" - ;; operators don't get a face. - (let ((code "{ $a++ / $b }")) - (should (equal (nth 8 (cperl-test-ppss code "/")) nil))) - (let ((code "{ $a-- / $b }")) - (should (equal (nth 8 (cperl-test-ppss code "/")) nil))) - ;; The next two Perl expressions have regular expressions. The - ;; delimiter of a RE is fontified with font-lock-constant-face. - (let ((code "{ $a+ / $b } # /")) - (should (equal (nth 8 (cperl-test-ppss code "/")) 7))) - (let ((code "{ $a- / $b } # /")) - (should (equal (nth 8 (cperl-test-ppss code "/")) 7)))) +(defmacro cperl--run-test-cases (file &rest body) + "Run all test cases in FILE with BODY. +This macro helps with tests which reformat Perl code, e.g. when +indenting or rearranging flow control. It extracts source code +snippets and corresponding expected results from a resource file, +runs BODY on the snippets, and compares the resulting buffer with +the expected results. -(ert-deftest cperl-mode-test-bug-16368 () - "Verify that `cperl-forward-group-in-re' doesn't hide errors." +Test cases in FILE are formatted like this: + +# -------- NAME: input -------- +Your input to the test case comes here. +Both input and expected output may span several lines. +# -------- NAME: expected output -------- +The expected output from running BODY on the input goes here. +# -------- NAME: end -------- + +You can have many of these blocks in one test file. You can +chose a NAME for each block, which is passed to the 'should' +clause for easy identification of the first test case that +failed (if any). Text outside these the blocks is ignored by the +tests, so you can use it to document the test cases if you wish." + `(with-temp-buffer + (insert-file-contents ,file) + (goto-char (point-min)) + (while (re-search-forward + (concat "^# ?-+ \\_<\\(?1:.+?\\)\\_>: input ?-+\n" + "\\(?2:\\(?:.*\n\\)+?\\)" + "# ?-+ \\1: expected output ?-+\n" + "\\(?3:\\(?:.*\n\\)+?\\)" + "# ?-+ \\1: end ?-+") + nil t) + (let ((name (match-string 1)) + (code (match-string 2)) + (expected (match-string 3)) + got) + (with-temp-buffer + (insert code) + (goto-char (point-min)) + (funcall cperl-test-mode) + ,@body + (setq expected (concat "test case " name ":\n" expected)) + (setq got (concat "test case " name ":\n" (buffer-string))) + (should (equal got expected))))))) + +;;; Indentation tests + +(ert-deftest cperl-test-indent-exp () + "Run various tests for `cperl-indent-exp' edge cases. +These exercise some standard blocks and also the special +treatment for Perl expressions where a closing paren isn't the +end of the statement." (skip-unless (eq cperl-test-mode #'cperl-mode)) - (let ((code "/(\\d{4})(?{2}/;") ; the regex from the bug report - (result)) - (with-temp-buffer - (insert code) - (goto-char 9) - (setq result (cperl-forward-group-in-re)) - (should (equal (car result) 'scan-error)) - (should (equal (nth 1 result) "Unbalanced parentheses")) - (should (= (point) 9)))) ; point remains unchanged on error - (let ((code "/(\\d{4})(?{2})/;") ; here all parens are balanced - (result)) + (cperl--run-test-cases + (ert-resource-file "cperl-indent-exp.pl") + (cperl-indent-exp))) ; here we go! + +(ert-deftest cperl-test-indent-styles () + (skip-unless (eq cperl-test-mode #'cperl-mode)) + (cperl--run-test-cases + (ert-resource-file "cperl-indent-styles.pl") + (cperl-set-style "PBP") + (indent-region (point-min) (point-max)) ; here we go! + (cperl-set-style-back))) + +;;; Fontification tests + +(ert-deftest cperl-test-fontify-punct-vars () + "Test fontification of Perl's punctiation variables. +Perl has variable names containing unbalanced quotes for the list +separator $\" and pre- and postmatch $` and $'. A reference to +these variables, for example \\$\", should not cause the dollar +to be escaped, which would then start a string beginning with the +quote character. This used to be broken in cperl-mode at some +point in the distant past, and is still broken in perl-mode. " + (skip-unless (eq cperl-test-mode #'cperl-mode)) + (let ((file (ert-resource-file "fontify-punctuation-vars.pl"))) (with-temp-buffer - (insert code) - (goto-char 9) - (setq result (cperl-forward-group-in-re)) - (should (equal result nil)) - (should (= (point) 15))))) ; point has skipped the group + (insert-file-contents file) + (goto-char (point-min)) + (funcall cperl-test-mode) + (while (search-forward "##" nil t) + ;; The third element of syntax-ppss is true if in a string, + ;; which would indicate bad interpretation of the quote. The + ;; fourth element is true if in a comment, which should be the + ;; case. + (should (equal (nth 3 (syntax-ppss)) nil)) + (should (equal (nth 4 (syntax-ppss)) t)))))) -(defun cperl-mode-test--run-bug-10483 () +;;; Tests for issues reported in the Bug Tracker + +(defun cperl-test--run-bug-10483 () "Runs a short program, intended to be under timer scrutiny. This function is intended to be used by an Emacs subprocess in batch mode. The message buffer is used to report the result of @@ -102,7 +154,7 @@ cperl-mode-test--run-bug-10483 (cperl-indent-exp) (message "%s" (buffer-string))))) -(ert-deftest cperl-mode-test-bug-10483 () +(ert-deftest cperl-test-bug-10483 () "Check that indenting certain perl code does not loop forever. This verifies that indenting a piece of code that ends in a paren without a statement terminator on the same line does not loop @@ -113,7 +165,7 @@ cperl-mode-test-bug-10483 (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; FIXME times out (skip-unless (not (< emacs-major-version 28))) ; times out in older Emacsen (let* ((emacs (concat invocation-directory invocation-name)) - (test-function 'cperl-mode-test--run-bug-10483) + (test-function 'cperl-test--run-bug-10483) (test-function-name (symbol-name test-function)) (test-file (symbol-file test-function 'defun)) (ran-out-of-time nil) @@ -138,156 +190,54 @@ cperl-mode-test-bug-10483 (should (string-match "poop ('foo', \n 'bar')" (buffer-string)))))) -(ert-deftest cperl-mode-test-indent-exp () - "Run various tests for `cperl-indent-exp' edge cases. -These exercise some standard blocks and also the special -treatment for Perl expressions where a closing paren isn't the -end of the statement." - (skip-unless (eq cperl-test-mode #'cperl-mode)) - (let ((file (ert-resource-file "cperl-indent-exp.pl"))) - (with-temp-buffer - (insert-file-contents file) - (goto-char (point-min)) - (while (re-search-forward - (concat "^# ?-+ \\_<\\(?1:.+?\\)\\_>: input ?-+\n" - "\\(?2:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: expected output ?-+\n" - "\\(?3:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: end ?-+") - nil t) - (let ((name (match-string 1)) - (code (match-string 2)) - (expected (match-string 3)) - got) - (with-temp-buffer - (insert code) - (cperl-mode) - (goto-char (point-min)) - (cperl-indent-exp) ; here we go! - (setq expected (concat "test case " name ":\n" expected)) - (setq got (concat "test case " name ":\n" (buffer-string))) - (should (equal got expected)))))))) - -(ert-deftest cperl-mode-test-indent-styles () - "Verify correct indentation by style \"PBP\". -Perl Best Practices sets some indentation values different from - the defaults, and also wants an \"else\" or \"elsif\" keyword - to align with the \"if\"." - (let ((file (ert-resource-file "cperl-indent-styles.pl"))) - (with-temp-buffer - (cperl-set-style "PBP") - (insert-file-contents file) - (goto-char (point-min)) - (while (re-search-forward - (concat "^# ?-+ \\_<\\(?1:.+?\\)\\_>: input ?-+\n" - "\\(?2:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: expected output ?-+\n" - "\\(?3:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: end ?-+") - nil t) - (let ((name (match-string 1)) - (code (match-string 2)) - (expected (match-string 3)) - got) - (with-temp-buffer - (insert code) - (cperl-mode) - (indent-region (point-min) (point-max)) ; here we go! - (setq expected (concat "test case " name ":\n" expected)) - (setq got (concat "test case " name ":\n" (buffer-string))) - (should (equal got expected))))) - (cperl-set-style "CPerl")))) - -(ert-deftest cperl-mode-fontify-punct-vars () - "Test fontification of Perl's punctiation variables. -Perl has variable names containing unbalanced quotes for the list -separator $\" and pre- and postmatch $` and $'. A reference to -these variables, for example \\$\", should not cause the dollar -to be escaped, which would then start a string beginning with the -quote character. This used to be broken in cperl-mode at some -point in the distant past, and is still broken in perl-mode. " +(ert-deftest cperl-test-bug-16368 () + "Verify that `cperl-forward-group-in-re' doesn't hide errors." (skip-unless (eq cperl-test-mode #'cperl-mode)) - (let ((file (ert-resource-file "fontify-punctuation-vars.pl"))) + (let ((code "/(\\d{4})(?{2}/;") ; the regex from the bug report + (result)) (with-temp-buffer - (insert-file-contents file) - (goto-char (point-min)) - (funcall cperl-test-mode) - (while (search-forward "##" nil t) - ;; The third element of syntax-ppss is true if in a string, - ;; which would indicate bad interpretation of the quote. The - ;; fourth element is true if in a comment, which should be the - ;; case. - (should (equal (nth 3 (syntax-ppss)) nil)) - (should (equal (nth 4 (syntax-ppss)) t)))))) - -(ert-deftest cperl-bug30393 () - "Verify that indentation is not disturbed by an open paren in col 0. -Perl is not Lisp: An open paren in column 0 does not start a function." - (let ((file (ert-resource-file "cperl-bug-30393.pl"))) + (insert code) + (goto-char 9) + (setq result (cperl-forward-group-in-re)) + (should (equal (car result) 'scan-error)) + (should (equal (nth 1 result) "Unbalanced parentheses")) + (should (= (point) 9)))) ; point remains unchanged on error + (let ((code "/(\\d{4})(?{2})/;") ; here all parens are balanced + (result)) (with-temp-buffer - (insert-file-contents file) - (goto-char (point-min)) - (while (re-search-forward - (concat "^# ?-+ \\_<\\(?1:.+?\\)\\_>: input ?-+\n" - "\\(?2:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: expected output ?-+\n" - "\\(?3:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: end ?-+") - nil t) - (let ((name (match-string 1)) - (code (match-string 2)) - (expected (match-string 3)) - got) - (with-temp-buffer - (insert code) - (funcall cperl-test-mode) - (goto-char (point-min)) - (while (null (eobp)) - (cperl-indent-command) - (forward-line 1)) - (setq expected (concat "test case " name ":\n" expected)) - (setq got (concat "test case " name ":\n" (buffer-string))) - (should (equal got expected)))))))) + (insert code) + (goto-char 9) + (setq result (cperl-forward-group-in-re)) + (should (equal result nil)) + (should (= (point) 15))))) ; point has skipped the group -(ert-deftest cperl-bug19709 () +(ert-deftest cperl-test-bug-19709 () "Verify that indentation of closing paren works as intended. Note that Perl mode has no setting for close paren offset, per documentation it does the right thing anyway." - (let ((file (ert-resource-file "cperl-bug-19709.pl"))) - (with-temp-buffer - (insert-file-contents file) - (goto-char (point-min)) - (while (re-search-forward - (concat "^# ?-+ \\_<\\(?1:.+?\\)\\_>: input ?-+\n" - "\\(?2:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: expected output ?-+\n" - "\\(?3:\\(?:.*\n\\)+?\\)" - "# ?-+ \\1: end ?-+") - nil t) - (let ((name (match-string 1)) - (code (match-string 2)) - (expected (match-string 3)) - got) - (with-temp-buffer - (insert code) - (funcall cperl-test-mode) - (setq-local - ;; settings from the bug report - cperl-indent-level 4 - cperl-indent-parens-as-block t - cperl-close-paren-offset -4 - ;; same, adapted for per-mode - perl-indent-level 4 - perl-indent-parens-as-block t) - (goto-char (point-min)) - (while (null (eobp)) - (cperl-indent-command) - (next-line)) - (setq expected (concat "test case " name ":\n" expected)) - (setq got (concat "test case " name ":\n" (buffer-string))) - (should (equal got expected)))))))) + (cperl--run-test-cases + (ert-resource-file "cperl-bug-19709.pl") + ;; settings from the bug report + (setq-local cperl-indent-level 4) + (setq-local cperl-indent-parens-as-block t) + (setq-local cperl-close-paren-offset -4) + ;; same, adapted for per-mode + (setq-local perl-indent-level 4) + (setq-local perl-indent-parens-as-block t) + (while (null (eobp)) + (cperl-indent-command) + (forward-line 1)))) -(ert-deftest cperl-bug37127 () +(ert-deftest cperl-test-bug-30393 () + "Verify that indentation is not disturbed by an open paren in col 0. +Perl is not Lisp: An open paren in column 0 does not start a function." + (cperl--run-test-cases + (ert-resource-file "cperl-bug-30393.pl") + (while (null (eobp)) + (cperl-indent-command) + (forward-line 1)))) + +(ert-deftest cperl-test-bug-37127 () "Verify that closing a paren in a regex goes without a message. Also check that the message is issued if the regex terminator is missing." @@ -327,4 +277,24 @@ cperl-bug37127 (should (string-match "^End of .* string/RE" collected-messages))))) +(ert-deftest cperl-test-bug-42168 () + "Verify that '/' is a division after ++ or --, not a regexp. +Reported in https://github.com/jrockway/cperl-mode/issues/45. +If seen as regular expression, then the slash is displayed using +font-lock-constant-face. If seen as a division, then it doesn't +have a face property." + :tags '(:fontification) + ;; The next two Perl expressions have divisions. Perl "punctuation" + ;; operators don't get a face. + (let ((code "{ $a++ / $b }")) + (should (equal (nth 8 (cperl-test-ppss code "/")) nil))) + (let ((code "{ $a-- / $b }")) + (should (equal (nth 8 (cperl-test-ppss code "/")) nil))) + ;; The next two Perl expressions have regular expressions. The + ;; delimiter of a RE is fontified with font-lock-constant-face. + (let ((code "{ $a+ / $b } # /")) + (should (equal (nth 8 (cperl-test-ppss code "/")) 7))) + (let ((code "{ $a- / $b } # /")) + (should (equal (nth 8 (cperl-test-ppss code "/")) 7)))) + ;;; cperl-mode-tests.el ends here -- 2.20.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 11 04:43:24 2020 Received: (at 44561) by debbugs.gnu.org; 11 Nov 2020 09:43:24 +0000 Received: from localhost ([127.0.0.1]:40235 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcmex-0006AE-Ua for submit@debbugs.gnu.org; Wed, 11 Nov 2020 04:43:24 -0500 Received: from quimby.gnus.org ([95.216.78.240]:35380) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcmew-00069z-7e for 44561@debbugs.gnu.org; Wed, 11 Nov 2020 04:43:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID :In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=t0ubzGdmUTUrAJJcy62tWrOd6Wf4RIX2w9LTTREvfQA=; b=axCEnTjzMJsM/sXg1YlcnHd+J+ Bjx94fmN9rvHerMhEa/6Xh2R55JlgjQ1stJLHhchy8WwnpjdcQx5VCYqTKXuTxVufLRmFfOmxfwBp 8Mx0DT6GbA3S2hxaPpU1V7yYjGtV1BdWcwkJ8a6AYzcIwWeVB+v3LD4neIPUg+L2l3+0=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kcmec-0008IZ-TR; Wed, 11 Nov 2020 10:43:15 +0100 From: Lars Ingebrigtsen To: haj@posteo.de (Harald =?utf-8?Q?J=C3=B6rg?=) Subject: Re: bug#44561: [PATCH] 28.0; cperl-mode: Test file makeover References: <87mtzo27il.fsf@hajtower> X-Now-Playing: =?utf-8?B?UsOzaXPDrW4=?= Murphy's _The Rumble_: "The Rumble" Date: Wed, 11 Nov 2020 10:43:01 +0100 In-Reply-To: <87mtzo27il.fsf@hajtower> ("Harald =?utf-8?Q?J=C3=B6rg=22's?= message of "Tue, 10 Nov 2020 23:04:34 +0100") Message-ID: <87mtzodyai.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: haj@posteo.de (Harald Jörg) writes: > As the number of tests for (c)perl mode increases, the test file turns > out to be somewhat untidy. The patch establishes a consistent naming > scheme, factors out a piece of code which is used in s [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44561 Cc: 44561@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) haj@posteo.de (Harald J=C3=B6rg) writes: > As the number of tests for (c)perl mode increases, the test file turns > out to be somewhat untidy. The patch establishes a consistent naming > scheme, factors out a piece of code which is used in several tests, and > reorders the tests. > > The patch also eliminates a warning caused by using (next-line) instead > of (forward-line 1), and allows the tests to run under Emacs 26. Thanks; applied to the trunk. --=20 (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 11 04:43:29 2020 Received: (at control) by debbugs.gnu.org; 11 Nov 2020 09:43:29 +0000 Received: from localhost ([127.0.0.1]:40238 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcmf3-0006AV-63 for submit@debbugs.gnu.org; Wed, 11 Nov 2020 04:43:29 -0500 Received: from quimby.gnus.org ([95.216.78.240]:35394) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcmf2-0006AB-9R for control@debbugs.gnu.org; Wed, 11 Nov 2020 04:43:28 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=COmIBrmO9GKCqeyYpmbT2XL+titpyIgZp0AdWQ4MMms=; b=f6xVKeZ2LuFgZQlbzjW2DpbIF/ HiiQ37fUtxfaSYKhQhAlTGFCwUVrsW2uWe8jU5Eic0IEvv9XEBPXeA4h7knsTqeg0TwjwhJsD6giF u5l4pDGg9r43Znobz0yDepAtRmnDWvewBDykFLJ8kPfR7Ox0bHXuiforVsqensma+xH4=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kcmet-0008Il-Mj for control@debbugs.gnu.org; Wed, 11 Nov 2020 10:43:22 +0100 Date: Wed, 11 Nov 2020 10:43:18 +0100 Message-Id: <87lff8dya1.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #44561 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 44561 fixed close 44561 28.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 44561 fixed close 44561 28.1 quit From unknown Mon Aug 11 21:14:53 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 09 Dec 2020 12:24:10 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator