Commit 85c03036 authored by ryszard.szopa's avatar ryszard.szopa
Browse files

tests updated.

darcs-hash:7584a5ad6675052b6b4d6689b3a8bdbcd6a14a79
parent ac40f6e7
......@@ -8,7 +8,7 @@
(pomo:with-connection ( "test" "richard" "dupa" "localhost")
(postmodern:with-connection ( "test" "richard" "dupa" "localhost")
(postmodern:execute "CREATE DATABASE \"submarine-test\";"))
(defmacro defdao-example (name supers &body body)
......@@ -27,12 +27,13 @@ metaclass set to HTML and the right connection-spec."
((name :initarg :name :accessor person-name :type string)
(affiliation :accessor person-affiliation :type affiliation
:initform nil
:foreign t
:initarg :affiliation)))
(defdao-example club ()
((name :initarg :name :accessor club-name :type string)))
(def-many-to-many person club)
(def-many-to-many person club ("submarine-test" "richard" "dupa" "localhost"))
;this may at first complain
;seaying that the class person
;doesn't exist. Run this again
......@@ -56,13 +57,14 @@ metaclass set to HTML and the right connection-spec."
(defdao-example person ()
((name :initarg :name :accessor person-name :type string)
(affiliation :accessor person-affiliation :type affiliation
:foreign t
:initform nil
:initarg :affiliation)))
(defdao-example club ()
((name :initarg :name :accessor club-name :type string)))
(def-many-to-many person club)))
(def-many-to-many person club ("submarine-test" "richard" "dupa" "localhost"))))
(test save-dao
......@@ -129,6 +131,7 @@ metaclass set to HTML and the right connection-spec."
(run!)
(sleep 3)
(pomo:clear-connection-pool)
(pomo:with-connection ( "test" "richard" "dupa" "localhost")
(postmodern:execute "DROP DATABASE \"submarine-test\";"))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment