summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNic Ferier <nic@ferrier.me.uk>2013-06-12 01:27:31 +0100
committerNic Ferier <nic@ferrier.me.uk>2013-06-12 01:27:31 +0100
commit7db4f9c769dfaa1d065ecc0c698baee578f2066c (patch)
tree080c1116356daa0ba8ab246c2a1389f63ea119ed
parent836301c46e831fcbde8ce40952d5e722bd045e79 (diff)
add tests for let-while.
-rw-r--r--let-while-tests.el15
1 files changed, 15 insertions, 0 deletions
diff --git a/let-while-tests.el b/let-while-tests.el
new file mode 100644
index 0000000..50e9356
--- /dev/null
+++ b/let-while-tests.el
@@ -0,0 +1,15 @@
+;;; let-while-tests.el -- tests for the let-while macro
+
+
+(defun let-while-test ()
+ (catch :io
+ (let ((lines '("line 1" "line 2")))
+ (noflet ((get-line ()
+ (or
+ (pop lines)
+ (throw :io :eof))))
+ (let-while (line (get-line))
+ (message "the line is: %s" line))))))
+
+
+;;; let-while-tests.el ends here