Permalink
Browse files

Add test for pop with PersistentVector

  • Loading branch information...
Bronsa authored and David Nolen committed Apr 19, 2012
1 parent c2737ff commit 053b7fd9cbb0a24617592f490893d6a746e54ec7
Showing with 8 additions and 0 deletions.
  1. +8 −0 test/cljs/cljs/core_test.cljs
@@ -898,6 +898,14 @@
(assert (= (nth pv 97 nil) nil))
(assert (= (pv 96) 96)))
+ (let [pv (vec (range 33))]
+ (assert (= pv
+ (-> pv
+ pop
+ pop
+ (conj 31)
+ (conj 32)))))
+
(let [stack1 (pop (vec (range 97)))
stack2 (pop stack1)]
(assert (= 95 (peek stack1)))

0 comments on commit 053b7fd

Please sign in to comment.