comparison tests/automated/database-tests.el @ 4855:189fb67ca31a

Create Assert-eq, Assert-equal, etc. These are equivalent to (Assert (eq ...)) but display both the actual value and the expected value of the comparison. Use them throughout the test suite.
author Ben Wing <ben@xemacs.org>
date Thu, 14 Jan 2010 02:18:03 -0600
parents abe6d1db359e
children 0f66906b6e37
comparison
equal deleted inserted replaced
4854:95c4ced5c07c 4855:189fb67ca31a
44 (ignore-file-errors (delete-file fn)))) 44 (ignore-file-errors (delete-file fn))))
45 45
46 (test-database (db) 46 (test-database (db)
47 (Assert (databasep db)) 47 (Assert (databasep db))
48 (put-database "key1" "val1" db) 48 (put-database "key1" "val1" db)
49 (Assert (equal "val1" (get-database "key1" db))) 49 (Assert-equal "val1" (get-database "key1" db))
50 (remove-database "key1" db) 50 (remove-database "key1" db)
51 (Assert (equal nil (get-database "key1" db))) 51 (Assert-equal nil (get-database "key1" db))
52 (close-database db) 52 (close-database db)
53 (Assert (not (database-live-p db))) 53 (Assert (not (database-live-p db)))
54 (Assert (databasep db)))) 54 (Assert (databasep db))))
55 55
56 (let ((filename (expand-file-name "test-harness" (temp-directory)))) 56 (let ((filename (expand-file-name "test-harness" (temp-directory))))