* lisp/progmodes/cperl-mode.el (cperl--package-regexp):
Avoid double repetition; cperl--ws-or-comment-regexp is already
repeated with 1+.
* test/lisp/textmodes/dns-mode-tests.el
(dns-mode-tests-dns-mode-soa-increment-serial): Escape literal '$'.
* test/lisp/emacs-lisp/rx-tests.el (rx-regexp): Modify test to not
trigger a linting warning while retaining its testing power.
(group (regexp ,cperl--normal-identifier-regexp))
(opt
(sequence
- (1+ (regexp ,cperl--ws-or-comment-regexp))
+ (regexp ,cperl--ws-or-comment-regexp)
(group (regexp ,cperl--version-regexp))))))
"A regular expression for package NAME VERSION in Perl.
Contains two groups for the package name and version.")
(ert-deftest rx-regexp ()
(should (equal (rx (regexp "abc") (regex "[de]"))
"\\(?:abc\\)[de]"))
+ (should (equal (rx "a" (regexp "$"))
+ "a\\(?:$\\)"))
(let ((x "a*"))
(should (equal (rx (regexp x) "b")
"\\(?:a*\\)b"))
- (should (equal (rx "a" (regexp "*"))
- "a\\(?:*\\)"))
(should (equal (rx "" (regexp x) (eval ""))
"a*"))))
(dns-mode-soa-increment-serial)
;; Number is updated from 2015080302 to the current date
;; (actually, just ensure the year part is later than 2020).
- (should (string-match "$TTL 86400
+ (should (string-match "\\$TTL 86400
@ IN SOA ns.icann.org. noc.dns.icann.org. (
20[2-9][0-9]+ ;Serial
7200 ;Refresh