diff options
Diffstat (limited to 'test')
| -rw-r--r-- | test/automated/character-fold-tests.el | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/automated/character-fold-tests.el b/test/automated/character-fold-tests.el index 2b1a15c9e76..40f0aecf449 100644 --- a/test/automated/character-fold-tests.el +++ b/test/automated/character-fold-tests.el | |||
| @@ -54,5 +54,15 @@ | |||
| 54 | (concat w1 "\s\n\s\t\f\t\n\r\t" w2) | 54 | (concat w1 "\s\n\s\t\f\t\n\r\t" w2) |
| 55 | (concat w1 (make-string 90 ?\s) w2))))) | 55 | (concat w1 (make-string 90 ?\s) w2))))) |
| 56 | 56 | ||
| 57 | (ert-deftest character-fold--test-fold-to-regexp () | ||
| 58 | (let ((character-fold-table (make-char-table 'character-fold-table))) | ||
| 59 | (aset character-fold-table ?a "abc") | ||
| 60 | (aset character-fold-table ?1 "123") | ||
| 61 | (aset character-fold-table ?\s "-!-") | ||
| 62 | (should (equal (character-fold-to-regexp "a1a1") | ||
| 63 | "abc123abc123")) | ||
| 64 | (should (equal (character-fold-to-regexp "a1 a 1") | ||
| 65 | "abc123\\(?: \\|-!--!-\\)abc\\(?: \\|-!-\\)123")))) | ||
| 66 | |||
| 57 | (provide 'character-fold-tests) | 67 | (provide 'character-fold-tests) |
| 58 | ;;; character-fold-tests.el ends here | 68 | ;;; character-fold-tests.el ends here |