fix(wpcarro/emacs): Use should macro in struct.el tests
:) Change-Id: Ia6b4697d002394a7e1d913031849b383ed424ad5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6013 Reviewed-by: wpcarro <wpcarro@gmail.com> Autosubmit: wpcarro <wpcarro@gmail.com> Tested-by: BuildkiteCI
This commit is contained in:
parent
a1dfbbe79e
commit
77aeb57c64
1 changed files with 3 additions and 4 deletions
|
@ -14,12 +14,11 @@
|
|||
(cl-defstruct dummy name age)
|
||||
(defvar struct--test-dummy (make-dummy :name "Roofus" :age 19))
|
||||
(struct-set! dummy name "Doofus" struct--test-dummy)
|
||||
(string= "Doofus" (dummy-name struct--test-dummy)))
|
||||
(should (string= "Doofus" (dummy-name struct--test-dummy))))
|
||||
|
||||
(ert-deftest struct-set ()
|
||||
(cl-defstruct dummy name age)
|
||||
(defvar struct--test-dummy (make-dummy :name "Roofus" :age 19))
|
||||
(let ((result (struct-set dummy name "Shoofus" struct--test-dummy)))
|
||||
(and
|
||||
(string= "Roofus" (dummy-name struct--test-dummy))
|
||||
(string= "Shoofus" (dummy-name result)))))
|
||||
(should (string= "Roofus" (dummy-name struct--test-dummy)))
|
||||
(should (string= "Shoofus" (dummy-name result)))))
|
||||
|
|
Loading…
Reference in a new issue