anchor.diff:      "plazyn returns 0 results if REPEATS is 0.")
   
   (ok (equal '(1 2 3 1 2 3)
  -           (next-upto-n (plazyn (lambda () (pseq '(1 2 3))) 2)))
  +           (next-upto-n (plazyn (lambda () (pseq '(1 2 3) 1)) 2)))
       "plazyn returns correct results.")
   
   ;; pcycles (FIX)
  
positive.code: ;; pstutter
  
  (ok (equal (list 1 1 1 2 2 2 3 3 3)
             (next-upto-n (pstutter 3 (pseq '(1 2 3)))))
      "pstutter returns correct results.")
  
  (ok (equal (list 2 3 3)
             (next-upto-n (pstutter (pseq '(0 1 2)) (pseq '(1 2 3)))))
      "pstutter returns correct results when its N is a pattern, and when N is 0.")
  
  ;; pdurstutter
  
  (ok (equal (list 2 3/2 3/2)
             (next-upto-n (pdurstutter (pseq '(1 2 3)) (pseq '(0 1 2)))))
      "pdurstutter returns correct results for value patterns.")
  
  (ok (equal (list 1 1/2 1/2) ;; FIX: correct this when events can be compared
             (gete (next-upto-n (pdurstutter (pbind :foo (pseries)) (pseq '(0 1 2)))) :dur))
      "pdurstutter returns correct results for event patterns when its N is a pattern, and when N is 0.")
  
  ;; pbeats
  
negative.code: ;; pif
  
  (ok (equal (list 1 2 4 5 3 nil 6)
             (next-n (pif (pseq (list t t nil nil t t nil) 1)
                          (pseq (list 1 2 3) 1)
                          (pseq (list 4 5 6) 1))
                     7))
      "pif returns correct results.")
  
  