Allow 'browse-url-emacs' to fetch URL in the selected window
[emacs.git] / test / lisp / buff-menu-tests.el
bloba942a5630d8a7f9d21c34598bf06a8cf42ec28b7
1 ;;; buff-menu-tests.el --- Test suite for buff-menu.el -*- lexical-binding: t -*-
3 ;; Copyright (C) 2016-2018 Free Software Foundation, Inc.
5 ;; Author: Tino Calancha <tino.calancha@gmail.com>
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 ;;; Code:
26 (require 'ert)
28 (ert-deftest buff-menu-24962 ()
29 "Test for https://debbugs.gnu.org/24962 ."
30 (let* ((file (make-temp-file "foo"))
31 (buf (find-file file)))
32 (unwind-protect
33 (progn
34 (rename-buffer " foo")
35 (list-buffers)
36 (with-current-buffer "*Buffer List*"
37 (should (string= " foo" (buffer-name (Buffer-menu-buffer))))))
38 (and (buffer-live-p buf) (kill-buffer buf))
39 (and (file-exists-p file) (delete-file file)))))
41 (provide 'buff-menu-tests)
43 ;;; buff-menu-tests.el ends here