r9261: more :base-table testing
authorKevin M. Rosenberg <kevin@rosenberg.net>
Thu, 6 May 2004 03:58:36 +0000 (03:58 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Thu, 6 May 2004 03:58:36 +0000 (03:58 +0000)
tests/test-fddl.lisp
tests/test-fdml.lisp
tests/test-init.lisp

index 71094847f379cfaddac9f747d298b74dfda0d1fc..2db453f25e5f8ba5a6878324db89e808c59504f3 100644 (file)
@@ -28,7 +28,7 @@
            (sort (mapcar #'string-downcase
                          (clsql:list-tables :owner *test-database-user*))
                  #'string<))
-  "address" "company" "ea_join" "employee" "type_table")
+  "addr" "company" "ea_join" "employee" "type_table")
 
 ;; create a table, test for its existence, drop it and test again 
 (deftest :fddl/table/2
@@ -64,7 +64,7 @@
            (sort 
             (mapcar #'string-downcase
                     (clsql:list-attributes [employee]
-                                          :owner *test-database-user*))
+                                          :owner *test-database-user*))
             #'string<))
   "birthday" "ecompanyid" "email" "emplid" "first_name" "groupid" "height"
   "last_name" "managerid" "married")
index 26e760e919937be497e3e54512b4725f478fc4a4..a4b8bb18ed2c016dc8b7c7762fa82d99359f0dfe 100644 (file)
 (deftest :fdml/select/15
     (multiple-value-bind (rows field-names)
        (clsql:select [addressid] [street-number] [street-name] [city_field] [zip] 
-        :from [address]
+        :from [addr]
         :where [= 1 [addressid]])
       (values
        rows
 (deftest :fdml/loop/2
     (loop for (addressid)
       being each tuple in
-      [select [addressid] :from [address] :order-by [addressid]]
+      [select [addressid] :from [addr] :order-by [addressid]]
      collect addressid)
   (1 2))
 
 (deftest :fdml/loop/3
     (loop for addressid
       being each tuple in
-      [select [addressid] :from [address] :order-by [addressid]]
+      [select [addressid] :from [addr] :order-by [addressid]]
       collect addressid)
   (1 2))
 
index a1f700e90c0f5374cf8d6ce087df1c2458c19cab..730169132db572e594d56de0d4ff815e6376ea4a 100644 (file)
     :db-info (:join-class employee
                          :home-key (companyid groupid)
                          :foreign-key (ecompanyid groupid)
-                         :set t)))
-  (:base-table company))
-
+                         :set t))))
 
 (def-view-class address ()
   ((addressid
     :column "zip"
     :type integer
     :void-value 0
-    :initarg :postal-code)))
+    :initarg :postal-code))
+  (:base-table addr))
 
 ;; many employees can reside at many addressess
 (def-view-class employee-address ()