diff options
Diffstat (limited to 'test/src')
| -rw-r--r-- | test/src/comp-tests.el | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/test/src/comp-tests.el b/test/src/comp-tests.el index f1acc42b8ca..931b9e06094 100644 --- a/test/src/comp-tests.el +++ b/test/src/comp-tests.el | |||
| @@ -314,12 +314,22 @@ | |||
| 314 | (1+ (let ((a 1) | 314 | (1+ (let ((a 1) |
| 315 | (_b) | 315 | (_b) |
| 316 | (_c)) | 316 | (_c)) |
| 317 | a))) | 317 | a))) |
| 318 | (defun comp-tests-insertn-f (a b c d) | ||
| 319 | ;; Binsert | ||
| 320 | (insert a b c d)) | ||
| 318 | 321 | ||
| 319 | (byte-compile #'comp-tests-discardn-f) | 322 | (byte-compile #'comp-tests-discardn-f) |
| 320 | (native-compile #'comp-tests-discardn-f) | 323 | (native-compile #'comp-tests-discardn-f) |
| 324 | (byte-compile #'comp-tests-insertn-f) | ||
| 325 | (native-compile #'comp-tests-insertn-f) | ||
| 321 | 326 | ||
| 322 | (should (= (comp-tests-discardn-f 10) 2))) | 327 | (should (= (comp-tests-discardn-f 10) 2)) |
| 328 | |||
| 329 | (should (string= (with-temp-buffer | ||
| 330 | (comp-tests-insertn-f "a" "b" "c" "d") | ||
| 331 | (buffer-string)) | ||
| 332 | "abcd"))) | ||
| 323 | 333 | ||
| 324 | (ert-deftest comp-tests-gc () | 334 | (ert-deftest comp-tests-gc () |
| 325 | "Try to do some longer computation to let the gc kick in." | 335 | "Try to do some longer computation to let the gc kick in." |