X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=tests%2Ftest-oodml.lisp;h=804248bcb09ff262a94145124a828c2e16cd1df5;hb=279b34c9e8e28545c8f2a0959acb01d90138eeda;hp=39d7eea3f5e40fdb9d80c8eed5801805146e087b;hpb=021d4ab301e290da50d80e2689a2e71129108248;p=clsql.git diff --git a/tests/test-oodml.lisp b/tests/test-oodml.lisp index 39d7eea..804248b 100644 --- a/tests/test-oodml.lisp +++ b/tests/test-oodml.lisp @@ -59,7 +59,7 @@ 3) (deftest :oodml/select/6 - (let ((a (caar (clsql:select 'address :where [= 1 [emplid]])))) + (let ((a (caar (clsql:select 'address :where [= 1 [addressid]])))) (values (slot-value a 'street-number) (slot-value a 'street-name) @@ -68,7 +68,7 @@ 10 "Park Place" "Leningrad" 123) (deftest :oodml/select/7 - (let ((a (caar (clsql:select 'address :where [= 2 [emplid]])))) + (let ((a (caar (clsql:select 'address :where [= 2 [addressid]])))) (values (slot-value a 'street-number) (slot-value a 'street-name) @@ -81,6 +81,27 @@ (clsql:select 'employee :flatp t :order-by [emplid])) (t t t nil nil nil nil nil nil nil)) +(deftest :oodml/select/9 + (mapcar #'(lambda (pair) + (list + (typep (car pair) 'address) + (typep (second pair) 'employee-address) + (slot-value (car pair) 'addressid) + (slot-value (second pair) 'addressid))) + (employee-addresses employee1)) + ((t t 1 1) (t t 2 2))) + +(deftest :oodml/select/10 + (mapcar #'(lambda (pair) + (list + (typep (car pair) 'address) + (typep (second pair) 'employee-address) + (slot-value (car pair) 'addressid) + (slot-value (second pair) 'addressid))) + (employee-addresses employee2)) + ((t t 2 2))) + + ;; tests update-records-from-instance (deftest :oodml/update-records/1 (values