aboutsummaryrefslogtreecommitdiffstats
path: root/test/src
diff options
context:
space:
mode:
authorAndrea Corallo2019-05-24 14:48:55 +0200
committerAndrea Corallo2020-01-01 11:33:38 +0100
commitbebd14acc1f646c79702fca4f7081df30a49a66c (patch)
tree83ad15959131667932b013a86bb4641a6b611042 /test/src
parent770e52e7001ccdd309a47cbf8b8c9862bfd44ab5 (diff)
downloademacs-bebd14acc1f646c79702fca4f7081df30a49a66c.tar.gz
emacs-bebd14acc1f646c79702fca4f7081df30a49a66c.zip
add aset
Diffstat (limited to 'test/src')
-rw-r--r--test/src/comp-tests.el18
1 files changed, 10 insertions, 8 deletions
diff --git a/test/src/comp-tests.el b/test/src/comp-tests.el
index be131f7de76..769cd086b5a 100644
--- a/test/src/comp-tests.el
+++ b/test/src/comp-tests.el
@@ -85,14 +85,16 @@
85 85
86 (should (= (comp-tests-length-f) 3))) 86 (should (= (comp-tests-length-f) 3)))
87 87
88(ert-deftest comp-tests-aref () 88(ert-deftest comp-tests-aref-aset ()
89 "Testing aref." 89 "Testing aref and aset."
90 (defun comp-tests-aref-f () 90 (defun comp-tests-aref-aset-f ()
91 (aref [1 2 3] 2)) 91 (let ((vec [1 2 3]))
92 (byte-compile #'comp-tests-aref-f) 92 (aset vec 2 100)
93 (native-compile #'comp-tests-aref-f) 93 (aref vec 2)))
94 94 (byte-compile #'comp-tests-aref-aset-f)
95 (should (= (comp-tests-aref-f) 3))) 95 (native-compile #'comp-tests-aref-aset-f)
96
97 (should (= (comp-tests-aref-aset-f) 100)))
96 98
97(ert-deftest comp-tests-ffuncall () 99(ert-deftest comp-tests-ffuncall ()
98 "Testing varset." 100 "Testing varset."