r9992: new function
[kmrcl.git] / tests.lisp
index 86e86bdbb19ac6f8067f6b0e8ada0b3f0e88c264..b555555c170c45c182922c8a46decfd23e700238 100644 (file)
     (make-url "pg" :anchor "then" :vars '(("a" . "5") ("b" . "pi")))
   "pg?a=5&b=pi#then")
 
+(defclass test-unique ()
+  ((a :initarg :a)
+   (b :initarg :b)))
+     
+
+(deftest :unique.1
+    (let ((list (list (make-instance 'test-unique :a 1 :b 1)
+                     (make-instance 'test-unique :a 2 :b 2)
+                     (make-instance 'test-unique :a 3 :b 2))))
+      (values
+       (unique-slot-values list 'a)
+       (unique-slot-values list 'b)))
+  (1 2 3) (1 2))
+
+(deftest :unique.2
+    (unique-slot-values nil 'a)
+  nil)
+     
+          
  ;;; MOP Testing
 
 ;; Disable attrib class until understand changes in sbcl/cmucl