* test/lisp/net/tramp-tests.el (tramp-test41-delay-load): New test.
[emacs.git] / test / lisp / soundex-tests.el
blob59bdfa4e01e29ab6cdea5af35c3134d5593480d7
1 ;;; soundex-tests.el --- tests for soundex.el -*- lexical-binding: t -*-
3 ;; Copyright (C) 2017 Free Software Foundation, Inc.
5 ;; Maintainer: emacs-devel@gnu.org
7 ;; This file is part of GNU Emacs.
9 ;; GNU Emacs is free software: you can redistribute it and/or modify
10 ;; it under the terms of the GNU General Public License as published by
11 ;; the Free Software Foundation, either version 3 of the License, or
12 ;; (at your option) any later version.
14 ;; GNU Emacs is distributed in the hope that it will be useful,
15 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;; GNU General Public License for more details.
19 ;; You should have received a copy of the GNU General Public License
20 ;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
22 ;;; Commentary:
24 ;; Test `soundex-test-names' originally adapted from code in
25 ;; soundex.el by Christian Plaunt <chris@bliss.berkeley.edu>
27 ;;; Code:
29 (require 'ert)
30 (require 'soundex)
32 (defconst soundex-test-name-list
33 '("Euler" "Gauss" "Hilbert" "Knuth" "Lloyd" "Lukasiewicz"
34 "Ellery" "Ghosh" "Heilbronn" "Kant" "Ladd" "Lissajous")
35 "Knuth's names to demonstrate the Soundex algorithm.")
37 (ert-deftest soundex-test-names ()
38 (should
39 (equal (mapcar #'soundex soundex-test-name-list)
40 '("E460" "G200" "H416" "K530" "L300" "L222"
41 "E460" "G200" "H416" "K530" "L300" "L222"))))
43 ;;; soundex-tests.el ends here