;;; cl-lib.el --- tests for emacs-lisp/cl-lib.el -*- lexical-binding:t -*-
-;; Copyright (C) 2013-2015 Free Software Foundation, Inc.
+;; Copyright (C) 2013-2016 Free Software Foundation, Inc.
;; This file is part of GNU Emacs.
(should (equal (cl-set-difference b b) e))
;; Note: this test (and others) is sensitive to the order of the
;; result, which is not documented.
- (should (equal (cl-set-difference a b) (list c2 "x" "" nil 'a)))
- (should (equal (cl-set-difference b a) (list 'x 'y)))
+ (should (equal (cl-set-difference a b) (list 'a nil "" "x" c2)))
+ (should (equal (cl-set-difference b a) (list 'y 'x)))
;; We aren't testing whether this is really using `eq' rather than `eql'.
(should (equal (cl-set-difference e e :test 'eq) e))
(should (equal (cl-set-difference b e :test 'eq) b))
(should (equal (cl-set-difference e b :test 'eq) e))
(should (equal (cl-set-difference b b :test 'eq) e))
- (should (equal (cl-set-difference a b :test 'eq) (list c2 "x" "" nil 'a)))
- (should (equal (cl-set-difference b a :test 'eq) (list 'x 'y)))
+ (should (equal (cl-set-difference a b :test 'eq) (list 'a nil "" "x" c2)))
+ (should (equal (cl-set-difference b a :test 'eq) (list 'y 'x)))
(should (equal (cl-union e e) e))
(should (equal (cl-union a e) a))
(def . ,(or `nil `(nil))))
t)))))
(ert-deftest cl-lib-struct-constructors ()
- (should (equal (documentation 'cl-lib--con-2 t)
- "Constructor docstring."))
+ (should (string-match "\\`Constructor docstring."
+ (documentation 'cl-lib--con-2 t)))
(should (mystruct-p (cl-lib--con-1)))
(should (mystruct-p (cl-lib--con-2))))